After the first days

Hi there,
wanna share my first experiences with all other beginners. maybe its interesting for some of you.
here are the lessons i learned:

  • read the community board :slight_smile:

  • install the expert routine (will install the REST API, a really great tool to query the definitions)

  • create backups daily

  • look here for the correct use of the definition part you will need, if you use the recommended tools, it will work like a charm.

  • define your things wisely (naming) and maybe define the things network state via Network Binding as seperate thing to check only physical, without the bridges communication.

  • define your items wisely (naming, grouping, labeling)

  • layouts last: if you try to choose CSS file templates in HabPanel, dont use them (comment out, or leave HabPanel-CSS-Field empty) while you working in HabPanel, maybe some cursor states are defined and this will may make the work harder. if youre done with defining, activate CSS

  • read, understand and try everything that sounds interesting for you, if it works, go to next.

  • dont give up!

12 Likes

I am still early in my journey but I think some persistence is needed to give a good starting state after restarting OH. This is the next thing for me to implement… I do not yet use HabPanel.

The first page is nearly done… really like the concept of openHab and thanks to ysc for the orange-tree CSS, tomorrow i will start to use transform maps

1 Like

Nice. Did you manage it to scale properly? How does it look on a tablet or your mobile device?

On a Win10 Tablet it look nice too, but the scale, especially the font size does not match the look on a laptop, that means no, i had to learn much more than only choose items per dummy-widget :slight_smile:
on my android phone it looks like the text breaking the layout, endless text parts…

Hallo again, all interested beginners… wanna share my thoughts of the last days…
I am really trying to understand the underlaying model, thats why i google a lot to find related things to this project, and voila here are the findings and maybe useful tipps:

Try to understand: https://angular.io/ (a coding framework for using files/data feeds in the presentation on lots of different devices). That means, no you don’t have to code something, only understand the fundamentals of the concept of angular.

If you want to store some item-states into your own database, you need a database persistence service, the round-robin database rrd4j seems a good choice, but in the windows world i am pretty unsure that a ‘CRON-Job’ will run out of the box without installing some additional software. For sure the whole project is some linux-world driven part, and without a basic programming knowledge you get lost. For a lot of beginners this would only be ‘copy-and-paste’ from the community and try if it works.

What i am really looking for is:
A lot of how-to’s!

  • Howto ‘start’! Not the install part, the part where all the small things which are packed into this (standard)-product will be described.

  • Howto ‘create a module with parameter boxes’ for easy re-using in the whole community.

  • Howto ‘use a own CSS-File’ and what to avoid for running in the HabPanel.

Maybe the information is everywhere (i really read a lot) but i was not able to find it.

And last but not least:
If i don’t want to use linux, what wouldn’t work and why, for example in a windows 10 installation… ?
CRON?

Thanks for any hints…

Thanks for

openHAB is a Java software, there is no dependency to GNU/Linux. In fact, there should be no difference at all. But there are some little differences, like backslash in paths instead of slash. a serial interface will use other names, and so on.
In question of Time cron, this is also part of Java, even rrd4j will work flawlessly.

1 Like

Thanks for explaining!

Now i give unix a try:
via. VirtualBox emulate a Raspberry-PII putting a debian on it and there i installed OpenHab (great performance on a surface laptop). A lot of things work out of the box but now i stuck like every unix beginner with the rights on filesystem to create a things file or to copy a 2.5 Addon to target directory… but i will learn this too.
But thats the big difference to a windows installation, there you have all rights and you can do whatever you want even without a sudo :slight_smile: or without command line…

No, you are emulating an x86 Linux server

No, The Windows System User has rights you do not have. On Linux root has total control.

No Jens
stick with the platform you are most comfortable with
Don’t try to learn OpenHAB and a new OS at the same time
You’ll have full hands learning OpenHAB
There is a new Windows installer in beta and working awesome!
someone help me please with a link

Thanks again for commenting and explaining, but the installation is not the problem, maybe i should explain what i am looking for:
i have a lot of old tablets, laptops,… i only want to use them, to show HabPanel on screens and only one of them will act as ‘server’.

and HERE is where the way leads to windows or unix (didn’t own a mac)

  • Windows Version is easy to install, only extract the ZIP-File to a location, configure your system and start the batchfile.
    If you want to remove it, logout and remove the whole path on filesystem and you are done.
    If you want to save your settings ‘add folders (USERDATA/CONF)’ to a new ZIP File and name it yyyymmdd_… (for example 20190901_OpenHab_Save.ZIP).
    It’s portable if you ZIP the whole openHab folder and extract on a different windows host, configure a few lines, start the batchfile and you are done!
    If you are familar with coding at command line in windows, everything in stable version works like a charm… use code . add the visual studio plugin and install SVG preview for explorer use. you are ready to go.

But i don’t want to serve with my windows laptop, i only want to develop there! This is where i take a look at the

  • Unix Version is easy to install too, if you know what apt-get will do and if you are know what a bash is. After installation take a look to the file system, on difference to windows there are a lot of different directories created widely spreaded, not only one path like in the windows world. Sure the information about where i can find for example the ‘items’-folder is documentated but is not quite that easy as in windows. But now i can try some scripts or examples i find, out of the box that’s nice. After working a few longer with it i get lost without knowledge about chmod and why i don’t have rights (maybe i don’t understand who is owner and why)… but thats only a short term problem.

The long way problem (for me) seems to define a system, which is portable (if i choose another old pc as server, i don’t want to install everything again and again) and which i can edit and work with in windows via visual code. But it has also to be able to to test and try

That’s where VirtualBox came in, emulating a CPU and running OS whatever i want to run, it’s portable and can run on many different host systems. Now i need to configure (currently) access to file system (openBSD) to be able to read and write my settings in every folder to openHab-Unix side installation. But i think this is a bad idea, on one side i get a portable version but on the other side i can only switch the host system to run the VB except i use a windows installed VB, am i right?

Maybe there is a much easier way to do this.
Thanks for any suggestion

Having the server on Unix makes sense, running virtualization for this single purpose does not.
I’d suggest to get a pair of Raspis (so you have identical spare HW you can use by moving SD card or backup/restore of raw disk contents). If you rather would like to stick with your old laptop that’s also fine (good because of the builtin “UPS”), then in case of HW failure you have to install from scratch to new (well, used but different) HW.
That’s not as difficult as it sounds. Get a newbie-friendly debian-like UNIX such as Ubuntu, 1) install it, 2) “manually” install openHABian on top and then 3) restore your OH config from backup. 1 & 2 you can prepare in advance so it won’t take long to get your system up and running again in case of HW failure.
Where to run your clients, rules editor etc is independent of that.

Being pedantic here.
If UNIX is recommended I assume one of the BSD flavors) why is Linux pushed so heavily? It is UNIX-like, but not UNIX.

Okay, strictly speaking you’re right. Linux is not UNIX and never will be due to the rights and licensing involved. Just like its major tools are GNU licensed.
I do think however to insist on correct speech will rather bedazzle all those poor Windows users we want to convince moving off Windows so I took the freedom to be inaccurate here …

1 Like

lol! yeah if i want to type anything so concrete as possible i will sure remind this :slight_smile:
But at the other hand, for a ‘normal win user’ there is the windows world and the unix (linux,bsd,redhat,ubuntu,…) world where i didn’t even know the differences between them (i can imagine that some underlying librarys are different from type to type and so for example the gui looks different,… but i even don’t know).

Would it be possible to construct something like this (or is it maybe realized and i didn’t see?):

/conf and all underlying files and directories are stored on a NAS (//myNAS/conf)
No matter from which system i start the server, the conf files from the NAS will be loaded and if something changes save them there again… if this works, do i need this for the /userdata too?

Well one key characteristics of UNIX (and everything that is just UNIX-like :wink:) is that “anything goes” BUT you have to understand it well to not hit a pitfall…
So in short to answer your question: yes but no, don’t do it. Don’t make your OH service dependent on external entities, even more so if you’re no expert in that matter.
There’s better solutions. You can also access files via Samba from your Windows client using VS code extensions.
openHABian comes with Amanda, a backup solution (that you should deploy in either case).
You can also upload your config e.g. to GitHub (hey, that’s M$ owned now, too !) or some other cloud service, but git is a practical approach quite some OH users make use of.
Just one thing: do NOT edit the files at their location in the filesystem. Make a copy, edit that copy then copy it back. Else you’ll run into trouble with OH.

1 Like

You forgot a step ;D

  1. Make a copy1 as a backup
  2. Make a copy2 to edit
  3. Copy it back
  4. If broken, copy copy1 into place to revert.

That sums up to … nothing :wink:

Make sure you have an original copy before overwriting the production version so you can revert back. Copying your edited file would overwrite you only original copy otherwise.

And to be even more pedantic… :wink:

Linux is the kernel.

If talking about a distribution like debian, ubuntu, suse… it’s GNU/Linux.