- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- running dtach on tty1 automatically after reboot.....
Operating System - Linux
1748000
Members
4969
Online
108757
Solutions
Forums
Categories
Company
Local Language
юдл
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
юдл
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-16-2003 09:51 PM
тАО10-16-2003 09:51 PM
running dtach on tty1 automatically after reboot...
hi all...
just want to know whether i can run dtach on tty1 automatically? meaning after i reboot the machine, dtach is already running and immediately i can run the application into its main console.
also, after i exit. this dtach process always run...
just want to know whether i can run dtach on tty1 automatically? meaning after i reboot the machine, dtach is already running and immediately i can run the application into its main console.
also, after i exit. this dtach process always run...
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-16-2003 09:57 PM
тАО10-16-2003 09:57 PM
Re: running dtach on tty1 automatically after reboot...
generally to execute command upon boot edit the file /etc/rc.local and add the commands there.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-16-2003 11:17 PM
тАО10-16-2003 11:17 PM
Re: running dtach on tty1 automatically after reboot...
Yes, go to /etc/rc.d/init.d, create a batch that says :
dtach -arguments you want >tty1
And at rc3.d or rc5.d, according on if you use text or graphical boot, add a line looking like
S93batchname, replacing batchname with the name you choose for your batch, and 93 by the highest number you see (if last number is 87, use 88, and so on).
hth
J
dtach -arguments you want >tty1
And at rc3.d or rc5.d, according on if you use text or graphical boot, add a line looking like
S93batchname, replacing batchname with the name you choose for your batch, and 93 by the highest number you see (if last number is 87, use 88, and so on).
hth
J
You can lean only on what resists you...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-17-2003 08:33 AM
тАО10-17-2003 08:33 AM
Re: running dtach on tty1 automatically after reboot...
You may also be able to put dtach in the inittab as the program to run on the tty's? I don't know much about dtach as I have never used it before, but I have some experience changing program that logs users in. Check out your inittab for a line such as this:
1:2345:respawn:/sbin/getty 38400 tty1
you may want to change the program from /sbin/getty to something else, for example a shell script that prints "You can't login here". I did that to my brother when he left his root passwd sticky noted to the bottom of his keyboard :)
If dtach is able to replace getty you could call it directly as long as it behaves in a way that init expects. ie, it dies cleanly :) Here is how init works:
init scans you inittab, sees the line for tty1 and forks a child that just waits for the process to finish and if it found a respawn it will start the process again. You could start any program you want to really.
Just an idea :)
Dave
1:2345:respawn:/sbin/getty 38400 tty1
you may want to change the program from /sbin/getty to something else, for example a shell script that prints "You can't login here". I did that to my brother when he left his root passwd sticky noted to the bottom of his keyboard :)
If dtach is able to replace getty you could call it directly as long as it behaves in a way that init expects. ie, it dies cleanly :) Here is how init works:
init scans you inittab, sees the line for tty1 and forks a child that just waits for the process to finish and if it found a respawn it will start the process again. You could start any program you want to really.
Just an idea :)
Dave
Clothes make the man, Naked people have little to no effect on society
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
News and Events
Support
© Copyright 2024 Hewlett Packard Enterprise Development LP