Tuesday, July 19, 2011

Adding start up to linux

On the list of things to do after an install of SVN was to get Ubuntu to start the service at boot. This procedure will work for almost anything you’d like to do at boot.

Step 1 – Create your script.
Simply create a new file (I called mine startsvn) and type the command you’d like to run

cd /etc/init.d/
sudo touch startsvn
sudo vi startsvn
svnserve -d -r /usr/local/svn/repository_name

Step 2 – Save the script in the /etc/init.d/ folder

Step 3 – Make the script executable
sudo chmod +x startsvn

Step 4 – Add the script to the boot sequence
sudo update-rc.d startsvn defaults

Another example say you want to start up your ColdFusion server at boot

Step 1 create a link to your coldfusion script
sudo ln -s /opt/coldfusion9/bin/coldfusion /etc/init.d/coldfusion

Step 2 update the boot sequence
sudo update-rc.d coldfusion defaults

0 comments:

Wiredwizrd

in memphis, tn morgan todd Located in Raleigh, NC Morgan Todd has over 15+ years experience, as a Sr. IT Analyst and Freelance Developer Working in lead positions with various high energy companies, and Marketing Firms Securing and Developing enterprise level applications A Professional Penetration Tester, performing code review and pen testing for PCI_DSS, HEPA, and SOXS compliance, functionality, and best practices. for various corporate clients.