HOWTO: ConsoleWD for Raspberry Pi Setup Instructions - Old version

I thought I would post the following for anyone who wants to set their Raspberry Pi up to run the WD Console automatically at boot. I had been looking for a way to run the WD Console on my Raspberry Pi and by using the file provided by Mihec I was able to get it up and running, but every time the RPi lost power it would re-boot, then stop at the login prompt. So I would have to login, then issue the command to start the WD Console. I finally found a way to have all of this done automatically, so now if the RPi reboots, it will automatically login, then start the WD Console. Doesn’t sound like it should have been very complicated to do, but it took some digging because no one would comment to give direction which would allow the application to actually do what it was supposed to do. It would run, but would error “not able to find ./cronwu” thus it would work correctly. Like I said, I found a way to make everything work as it should. Below is what I found.

There are 2 parts to the problem:
1.Automatically login.
2.Automatically launch the program.

Assuming you’re logging into the command prompt (no GUI):

To automatically login to the command prompt:

Create a file with sudo nano /etc/systemd/system/[email protected]/override.confwith the following content:
[Service]
ExecStart=
ExecStart=-/sbin/agetty --autologin pi --noclear %I $TERM

For some reason, it works with the 1st ExecStart but not without it, so I just include it.

To Automatically launch the program:

a. Open up .bashrc for configuration:

sudo nano .bashrc

b. Scroll down to the bottom and add the following lines:

cd consolewdfiles
sleep 5
./GoWdconsole.sh

c. Save and exit:

Ctrl+X, Y, Enter

d. reboot the RPi (now it will automatically login, then start the WD Console)

sudo reboot (press enter)

I hope this helps others out. I worked on it on/off for a few months before I finally figured it out. I am fairly new to the RPi, so it’s no surprise it took me this long.

Enjoy,
Rick