SunQuest
           Linux Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsOperating SystemsLinux Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now!
  #1  
Old August 25th, 2002, 08:28 AM
cashan cashan is offline
Go for php
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Posts: 3 cashan User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 42 m 34 sec
Reputation Power: 0
How to pipe in password for the root with out keyboard??

HI All
Is there any way to pipe in the password of the user, so that I don't have
to manually enter it? (i.e. - so that I can run this in a script)

Doing

echo "password" | su user -c"command"

it says "standard in must be a tty".

Can anyone tell me how to do it??


Thanks

Cashan

Reply With Quote
  #2  
Old August 27th, 2002, 06:01 AM
christo's Avatar
christo christo is offline
Introspective
Dev Shed Loyal (3000 - 3499 posts)
 
Join Date: Nov 2001
Location: London, UK
Posts: 3,296 christo User rank is Second Lieutenant (5000 - 10000 Reputation Level)christo User rank is Second Lieutenant (5000 - 10000 Reputation Level)christo User rank is Second Lieutenant (5000 - 10000 Reputation Level)christo User rank is Second Lieutenant (5000 - 10000 Reputation Level)christo User rank is Second Lieutenant (5000 - 10000 Reputation Level)christo User rank is Second Lieutenant (5000 - 10000 Reputation Level)christo User rank is Second Lieutenant (5000 - 10000 Reputation Level) 
Time spent in forums: 3 Days 1 h 5 m 42 sec
Reputation Power: 101
Send a message via ICQ to christo Send a message via Yahoo to christo
AFAIK, you can't
But you can play with SUID and write wrappers for the apps/commands that you most often use. I was thinking just this morning that it's a real bore having to

$su
$xxxxxxx
$shutdown -h now

everytime I turn off my macine - and a oneline

$powerdown

would be much more convenient.

Christo

Reply With Quote
  #3  
Old August 28th, 2002, 10:19 AM
freebsd freebsd is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2001
Posts: 5 freebsd User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
There is, so start here -> http://expect.nist.gov/FAQ.html

Reply With Quote
Reply

Viewing: Dev Shed ForumsOperating SystemsLinux Help > How to pipe in password for the root with out keyboard??


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway