- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Two question force logout and copy from buffer
Categories
Company
Local Language
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
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
Community
Resources
Forums
Blogs
- 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
тАО02-22-2014 10:38 PM - edited тАО02-22-2014 10:42 PM
тАО02-22-2014 10:38 PM - edited тАО02-22-2014 10:42 PM
Hi Everyone
1- sometime when I copy every text or command from terminal and paste it in for example notepad it work but sometimes not work!!
2- I use below command for force logout an user from server but when I copy this command to other terminal , not work??
ps -u username | while read a b c^Jdo^Jkill -9 $a^Jdone
thank you
Solved! Go to Solution.
- Tags:
- fore logout
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-23-2014 01:23 AM - edited тАО02-23-2014 04:58 AM
тАО02-23-2014 01:23 AM - edited тАО02-23-2014 04:58 AM
Re: Two questions force logout and copy from buffer
>1 sometime when I copy every text or command from terminal and paste it in notepad sometimes not work
This is more of a Windows issue, nothing to do with HP-UX. What doesn't work?
>2 I use below command for force logout an user from server but when I copy this command to other terminal, not work?
ps -u username | while read PID b c; do kill -9 $PID; done
In general you should never first use kill -9. You should do a normal kill first.
What doesn't work, the copy or the kill script fragment?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-23-2014 02:19 AM
тАО02-23-2014 02:19 AM
Re: Two question force logout and copy from buffer
thank you for your answer
in 1 case i connect to the server by windows software and in the new enviroment i can load a xterminal of hp-ux
.i am not in hp-ux directly.but i access to hp-ux by terminal.and copy from terminal somtimes work!!
in 2 case i dont want to one by one proccess i want the user has been force logout.this command work when i load that from history (ESc and /) but when i type or copy that it doesn't work.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-23-2014 04:58 AM
тАО02-23-2014 04:58 AM
Solution>I am not in HP-UX directly but I access to HP-UX by terminal and copy from terminal sometimes work
I use putty and don't have problems with cut&paste between it and Windows.
>in 2 case I don't want to one by one process... This command works when I load that from history (Esc and /) but when I type or copy that it doesn't work.
Instead of typing newlines, use semicolons as I had above:
ps -u username | while read PID b c; do kill -9 $PID; done
Or better yet, put it in a script.