HomeGenie no longer works

Started by dkbialik, December 22, 2019, 12:50:08 AM

Previous topic - Next topic

petera

Quote from: dkbialik on December 22, 2019, 04:12:17 PM
Here is the screen capture from Peter's post

I'm assuming you installed Mr T's X10 hub. Is that correct. I need Mr T to confirm the path of WorkingDirectory and ExecStart before you can proceed with my instructions as they won't work otherwise.

petera

Quote from: dkbialik on December 22, 2019, 04:16:04 PM
I am not sure.

Ok. How did you manage to install HG and HA Bridge in the first place

dkbialik


dkbialik

Originally installed from Tuiceman's image and then you personally assisted in getting them to work.

Tuicemen

type cd /usr/local/bin then type dir to see if HG is there
Please Read Topic:
General Forum Etiquette
Before you post!

petera

Quote from: dkbialik on December 22, 2019, 04:20:30 PM
yes the X10 hub is installed.

Ok we have that cleared up. Now all you need is for Mr T to confirm installation paths before you proceed. The default path for WorkingDirectory is /home/pi/homegenie but I'm not sure where yours is

dkbialik


Tuicemen

ok
WorkingDirectory=/usr/local/bin/homegenie
ExecStart=/usr/bin/mono /usr/local/bin/homegenie/HomeGenie.exe --log
Please Read Topic:
General Forum Etiquette
Before you post!

petera

Quote from: dkbialik on December 22, 2019, 04:29:45 PM
Looks like it is there

Ok Mr T has just confirmed the paths so replace them with the ones I supplied in Post #10 and proceed with the rest of those instructions.

dkbialik


petera

I'm reposting post #10 with the correct paths for HG as per Mr T. Please follow these instructions exactly as they are laid out
============================================================

Below is a sample Systemd file to launch the Homegenie service. You will need to adjust the paths of WorkingDirectory and ExecStart to reflect where your copy of HG is installed. If you want to reply back before you start work on what I have set out below it might be easier for you.

What you need to do is stop the current init.d service, disable it and create a new HG service and launch it. You will name the new service as homegenie1.service

cd

sudo systemctl stop homegenie.service

sudo systemctl disable homegenie.service

Now you create the new service called homegenie1.service

cd

sudo nano /etc/systemd/system/homegenie1.service

Now copy/paste the following lines below adjusting the paths as I mentioned above as soon Mr T supplies them. As soon as you finish press ctrl-x keys followed by the key y and press return.



[Unit]
Description=Homegenie Server
After=network.target

[Service]
WorkingDirectory=/usr/local/bin/homegenie
ExecStart=/usr/bin/mono /usr/local/bin/homegenie/HomeGenie.exe --log
Restart=always

[Install]
WantedBy=multi-user.target

Now you need to enable the new service you just created and start it.

cd

sudo systemctl enable homegenie1.service

sudo systemctl start homegenie1.service

To check your service is running type

sudo systemctl status homegenie1.service

Could you screen cap the output of the last command and post it.

dkbialik


dkbialik

All is restored.  Thank you, Petera an Tuiceman.

petera

Quote from: dkbialik on December 22, 2019, 05:06:20 PM
All is restored.  Thank you, Petera an Tuiceman.

There's no shortcuts to getting things working in Linux. Knocking out a few commands and crossing your fingers doesn't cut it.

You need to recognise the problem first and know where everything is located. Everything is located in particular folders for a reason, troubleshooting being one of them. It's best to stick with accepted norms.

Raspbian is a subset of Debian the full Linux OS. Unfortunately short cuts and bad habits have creeped in to Raspbian to such an extent that mistakes are beginning to happen which makes troubleshooting quite difficult. You saw how quickly your problem was solved as soon as the correct paths were supplied.

You now have a functioning HG and HA Bridge and as I advised you before take an image of your SD card before you proceed any further. It saves everyone all the headaches

dkbialik

thank you again.  I am still a novice with Raspberry and Linux, but intend on learning.

SMF spam blocked by CleanTalk