LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-03-2010, 01:57 PM   #1
Potatos
LQ Newbie
 
Registered: Apr 2010
Distribution: Fedora 13
Posts: 20

Rep: Reputation: 1
Opening a shell during boot


Is it possible to get /bin/sh to work in the init script?

What I'm looking to do is to have proc and sysfs mounted and then load a bash shell so I can browse the filesystem. Currently the init script is #!/bin/nash.

This is to allow me to perform actions manually that used be be done automatically in a linuxrc script.

The linuxrc script started with something like this if the user wanted to do the actions manually.

#!/bin/sh

mount -t proc /proc /proc
mount -t sysfs /sys /sys

/bin/sh

The kernel I'm booting is initramfs and loads off a USB key, its Cent OS 2.6.18-164.

Thanks for any help!
 
Old 05-03-2010, 02:55 PM   #2
rweaver
Senior Member
 
Registered: Dec 2008
Location: Louisville, OH
Distribution: Debian, CentOS, Slackware, RHEL, Gentoo
Posts: 1,833

Rep: Reputation: 164Reputation: 164
I'm curious why you would want to do this? Typically I'd just boot using a live cd then mount things as i wanted them...
 
Old 05-03-2010, 03:11 PM   #3
Potatos
LQ Newbie
 
Registered: Apr 2010
Distribution: Fedora 13
Posts: 20

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by rweaver View Post
I'm curious why you would want to do this? Typically I'd just boot using a live cd then mount things as i wanted them...
Partially because its how it was done before and I'm not sure how to change everything

However for a slightly better explanation the idea is that when the PC boots the first time it extracts a collection of .tgz files to create a standard filesystem on the machine. The linuxrc script would also install and configure some custom machine specific software. For further boots the user would skip the install option to open /bin/sh and just boot from the CD finding the extracted filesystem on the hard drive.

When new software has been developed a new CD burnt with new .tgz files and the install script is run again wiping everything and extracting an updated file system with the new software.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
opening a shell terminal in source directory ETRadix Linux - Newbie 2 01-07-2009 02:00 PM
opening a new shell? trscookie Linux - Software 3 07-25-2007 11:56 AM
opening a program from shell hari78 Linux - Newbie 4 03-08-2005 10:33 AM
opening file with .xls on linux shell prompt suchi_s Programming 1 07-28-2004 08:40 AM
Opening file with default application from shell script? bourbon_beast Programming 4 04-13-2004 02:52 AM


All times are GMT -5. The time now is 08:32 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration