I recently came across "remind" in Linux. I liked it almost immediately, but for my reminders to pop up, I needed to run 'remind' in daemon mode. Done quite simply using the following command:
remind -z -k'gmessage %s &' /home/googie/.reminders &
It would be lame for me to manually launch the 'remind' daemon every time I boot my computer (someone would have to remind me to do that!), so I thought I'll make it run automatically on boot. I was under the impression that this would be fairly straightforward to do, but I was in for a surprise.
I did the following (in this sequence):
- Made a script (with start, stop, restart cases), placed it in /etc/init.d, ran 'update-rc.d' to create some links for certain runlevels, restarted --- no luck
- Made a 'remind.conf' file, placed it in /etc/init (referring 'http://upstart.ubuntu.com/getting-started.html'), restarted --- still no luck
- Opened '/etc/rc.local', placed the command to start the 'remind' daemon just before 'exit 0', restarted --- still no luck
- Opened crontab (sudo crontab -e), wrote '@reboot' followed by the command to start the 'remind' daemon on the last line, restarted --- still no luck
- Opened 'System->Preferences->Startup Applications', added a new startup program with the command to start the 'remind' daemon, restarted --- still no luck
- Made a script in my home directory, placed the command to start the 'remind' daemon inside the script, called this script from '/etc/rc.local', restarted --- still no luck
- Called the script in my home directory after '@reboot' in crontab, restarted --- still no luck
- Called the script in my home directory using 'System->Preferences->Startup Applications' --- finally worked, and the 'remind' daemon now runs!!
So now for my 3 questions:
- Is it really so complicated in Linux to run something at startup, or is it just my lack of knowledge?
- Was trying steps 1 & 2 even advisable? I think these are used to make something a service. Isn't the 'remind' daemon a service as well?
- Why didn't the '/etc/rc.local' or 'crontab' approach work? Are there any logs I could check to see whats going wrong?
(any related references for me to read would be appreciated as well)