LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-01-2007, 07:28 AM   #1
freelancer42
LQ Newbie
 
Registered: Sep 2006
Posts: 17

Rep: Reputation: 0
Question Script requires terminal


I have a minor problem with a script that has to be started on 15 netbooting clients during bootup. It works when you manually start it from bash on each client, it works when you ssh to the clients separately ("ssh clienthostname") and manually start it. It DOESN'T work when started at a runlevel ("rc-update script.sh add default"), it doesn't work when you ssh to the clients separately and execute the script as a parameter ("ssh clienthostname ./script.sh") and it doesn't work when you dsh it to all of the clients ("dsh -a ./script.sh"). Hence my conclution that it requires an actual terminal (or something like that). Does anyone have a solution to this?

Btw, the clients are using Gentoo with an NFS-mounted root filesystem.
 
Old 02-01-2007, 07:40 AM   #2
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983
You can try the -l option to bash and execute the script as
Code:
bash -l script.sh
From the bash man page:
Quote:
-l Make bash act as if it had been invoked as a login shell
 
Old 02-01-2007, 08:09 AM   #3
freelancer42
LQ Newbie
 
Registered: Sep 2006
Posts: 17

Original Poster
Rep: Reputation: 0
It works! Thank you!
 
  


Reply

Tags
bash, gentoo, netboot, script, ssh, terminal



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
making a script that opens terminal and enter commands into that terminal Cinematography Linux - General 8 12-16-2008 10:34 AM
Adobe Acrobate Reader Requires A Plugin-That Requires Open LDAP That Requires Berkely Old_Fogie Slackware 10 05-08-2006 05:04 AM
problem with the terminal and a shell script LinuxPadawan Linux - General 1 05-17-2005 10:29 PM
Fluxbox startup script.......... App requires root. DraaX Slackware 2 11-28-2004 08:27 AM
is there a script that controls what happens when you switch a terminal? Fascistchicken Linux - General 2 09-29-2004 10:11 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:04 AM.

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
Open Source Consulting | Domain Registration