Do not do it this way,<br><br>If the startup file is in /etc/init.d, it is already in the startup system. You just have to check that it is set in the proper runlevel.<br><br>In the RedHat/SUSE world, use the command chkconfig.<br>
<br>In the Ubuntu world, use update-rc.d.<br><br>Learn the paradigm of the system you're in and use it and you'll have far fewer problems.<br><br>-Josh More<br><br><div class="gmail_quote">On Sun, Oct 2, 2011 at 8:30 PM, Charles Dunbar <span dir="ltr"><<a href="mailto:ccdunbar@gmail.com">ccdunbar@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">The easiest way I know (I do more redhat than debian, someone wiser<br>
might know more) would be to add the command in your crontab, since<br>
the init script doesn't seem to work well:<br>
<br>
$ sudo crontab -e<br>
<br>
Add the line:<br>
<br>
@reboot /usr/sbin/thttpd -C /etc/thttpd/thttpd.conf<br>
<br>
and save/exit the file editor.<br>
<br>
You can verify the full path of thttpd to see the exact file it's<br>
calling by typing:<br>
$ whereis thttpd<br>
<br>
Charles<br>
<br>
On Sun, Oct 2, 2011 at 7:53 PM, Tom Sellers <<a href="mailto:tomsellers2001@yahoo.com">tomsellers2001@yahoo.com</a>> wrote:<br>
> That's the ticket! I can see my root page now. How do I make it start this<br>
> way each time I boot up the server without having to manually start it each<br>
> time?<br>
><br>
> Thank you very much!<br>
> From: Charles Dunbar <<a href="mailto:ccdunbar@gmail.com">ccdunbar@gmail.com</a>><br>
> To: Central Iowa Linux Users Group <<a href="mailto:cialug@cialug.org">cialug@cialug.org</a>><br>
> Sent: Sunday, October 2, 2011 7:37 PM<br>
> Subject: Re: [Cialug] thttpd<br>
><br>
> Hey Tom,<br>
><br>
> I just did a double check on my Ubuntu 10.10 box, hopefully it's<br>
> similar enough to help you out.<br>
><br>
> After getting the package installed (sudo apt-get install thttpd), I<br>
> noticed it didn't auto-start like it says it does in the tutorial<br>
> you've linked.<br>
><br>
> Most programs usually have a script in /etc/init.d/(program name) that<br>
> takes "start, stop, status, restart" as basic arguments, to see if the<br>
> program is running, and to start/stop the program. thttpd's script in<br>
> /etc/init.d/ did absolutely nothing, printing no errors or anything,<br>
> so I just ran the command by itself<br>
><br>
> thttpd does not seem to work as I'd expect, with a "start" command in<br>
> the command, but trying it out reveled the arguments it could take:<br>
><br>
> $ sudo thttpd start<br>
> usage: thttpd [-C configfile] [-p port] [-d dir] [-r|-nor] [-dd<br>
> data_dir] [-s|-nos] [-v|-nov] [-g|-nog] [-u user] [-c cgipat] [-t<br>
> throttles] [-h host] [-l logfile] [-i pidfile] [-T charset] [-P P3P]<br>
> [-M maxage] [-V] [-D]<br>
><br>
><br>
> Specifying the config file caused the server to start up:<br>
><br>
> $ sudo thttpd -C /etc/thttpd/thttpd.conf<br>
><br>
> search for thttpd in output of ps aux:<br>
><br>
> $ ps aux | grep thttpd<br>
> www-data 23646 0.0 0.0 2312 616 ? Ss 19:31 0:00<br>
> thttpd -C /etc/thttpd/thttpd.conf<br>
><br>
><br>
> If you have any questions about the steps along the way, feel free to<br>
> ask. Jumping head first into Linux can be a bit daunting after years<br>
> of Windows.<br>
><br>
> Charles<br>
><br>
><br>
> On Sun, Oct 2, 2011 at 7:00 PM, Tom Sellers <<a href="mailto:tomsellers2001@yahoo.com">tomsellers2001@yahoo.com</a>><br>
> wrote:<br>
>> You are talking over my head with most of these questions.<br>
>><br>
>> I am the newbie of the group if you have been at the Des Moines meetings.<br>
>> I<br>
>> am trying to learn linux but it is quite different than I am use to since<br>
>> I<br>
>> have been a Windows guy for years.<br>
>><br>
>> As for the log file there is none created. I performed the install as the<br>
>> root user (sudo). How do I determine what user/permissions it is<br>
>> attempting<br>
>> to start under?<br>
>><br>
>> I followed a how to at the following web addresss.<br>
>><br>
>> <a href="http://radagast.bglug.ca/howto_build_a_server/howto_build_a_server_part1" target="_blank">http://radagast.bglug.ca/howto_build_a_server/howto_build_a_server_part1</a><br>
>><br>
>><br>
>> From: Nathan C. Smith <<a href="mailto:nathan.smith@ipmvs.com">nathan.smith@ipmvs.com</a>><br>
>> To: 'Central Iowa Linux Users Group' <<a href="mailto:cialug@cialug.org">cialug@cialug.org</a>><br>
>> Sent: Sunday, October 2, 2011 6:29 PM<br>
>> Subject: Re: [Cialug] thttpd<br>
>><br>
>> Check the log files to see if there are any reasons for it not to start?<br>
>> Is<br>
>> it starting under the correct user permissions? Does the user it is<br>
>> trying<br>
>> to run as have permissions to the config or for the content it is trying<br>
>> to<br>
>> serve?<br>
>><br>
>> -Nate<br>
>><br>
>> From: <a href="mailto:cialug-bounces@cialug.org">cialug-bounces@cialug.org</a> [mailto:<a href="mailto:cialug-bounces@cialug.org">cialug-bounces@cialug.org</a>] On<br>
>> Behalf<br>
>> Of Tom Sellers<br>
>> Sent: Sunday, October 02, 2011 6:11 PM<br>
>> To: Linux User Group Iowa<br>
>> Subject: [Cialug] thttpd<br>
>><br>
>> I installed thttpd on a server running Ubuntu 11.04 and can't seem to get<br>
>> it<br>
>> to start. I have examined the thttpd.conf file and compared it with an<br>
>> exmple that I found which did not turn up any issues. I created a short<br>
>> index.html file in the directory it told me to put it. However when I try<br>
>> to connect to the web page I get an error indicating the server is not<br>
>> running (no response!). I can ping the server from the machine I am<br>
>> attempting to browse from (on same local segment) but can't connect to the<br>
>> web page.<br>
>><br>
>> I used the ps -e command to see all the running processes and don't see<br>
>> thttpd in there anywhere.<br>
>><br>
>> I also looked in the directory where the log is to be but do not see any<br>
>> log<br>
>> there.<br>
>><br>
>> Anyone willing to help me out on this?<br>
>><br>
>> Thanks!<br>
>> _______________________________________________<br>
>> Cialug mailing list<br>
>> <a href="mailto:Cialug@cialug.org">Cialug@cialug.org</a><br>
>> <a href="http://cialug.org/mailman/listinfo/cialug" target="_blank">http://cialug.org/mailman/listinfo/cialug</a><br>
>><br>
>><br>
>><br>
>> _______________________________________________<br>
>> Cialug mailing list<br>
>> <a href="mailto:Cialug@cialug.org">Cialug@cialug.org</a><br>
>> <a href="http://cialug.org/mailman/listinfo/cialug" target="_blank">http://cialug.org/mailman/listinfo/cialug</a><br>
>><br>
>><br>
> _______________________________________________<br>
> Cialug mailing list<br>
> <a href="mailto:Cialug@cialug.org">Cialug@cialug.org</a><br>
> <a href="http://cialug.org/mailman/listinfo/cialug" target="_blank">http://cialug.org/mailman/listinfo/cialug</a><br>
><br>
><br>
><br>
> _______________________________________________<br>
> Cialug mailing list<br>
> <a href="mailto:Cialug@cialug.org">Cialug@cialug.org</a><br>
> <a href="http://cialug.org/mailman/listinfo/cialug" target="_blank">http://cialug.org/mailman/listinfo/cialug</a><br>
><br>
><br>
_______________________________________________<br>
Cialug mailing list<br>
<a href="mailto:Cialug@cialug.org">Cialug@cialug.org</a><br>
<a href="http://cialug.org/mailman/listinfo/cialug" target="_blank">http://cialug.org/mailman/listinfo/cialug</a><br>
</blockquote></div><br>