Sponsored Content
Top Forums Shell Programming and Scripting Logout script - delete a file Post 302378567 by AGGreenLinux on Tuesday 8th of December 2009 07:23:13 AM
Old 12-08-2009
rm command

Can you execute a rm command within a script to speed up the process?

Can the file be locked at login, how do you free it up to delete?
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

logout/shutdown script

I am running JDictd (http://www.informatik.uni-leipzig.de/~duc/Java/JDictd/) from tcsh in Terminal on Mac OS X (:=Darwin=FreeBSD/Mach). I am trying to get it to exit cleanly silently upon Mac OS X system shutdown. My idea was that if there was a logout script in FreeBSD (basically a script... (1 Reply)
Discussion started by: ropers
1 Replies

2. UNIX for Dummies Questions & Answers

Login and logout script

Hi all I know ho I can run a script when a user logs in, viz using the .login or .profile file, however what can I use to run a script when a user logouts ? Thanks J :confused: (1 Reply)
Discussion started by: jhansrod
1 Replies

3. Shell Programming and Scripting

run a script on logout by a non-root user

hi , i need to run a script that delete files when i logout as a user other than root user . I have tried out using .bash_logout but that doesnt seem to work , so any alternative for this to be done. Thanks in advance, Harsha (6 Replies)
Discussion started by: harsha10
6 Replies

4. UNIX for Dummies Questions & Answers

run a script at logout

hi all , Need to a run a program on user logout (using GNOME log screen). Tried using .bash_logout for this purpose but that doesnt seem to work. Similar to .bash_logout is there any script /program which a normal user (other than root ) can edit and run it on their logout? can anybody... (0 Replies)
Discussion started by: harsha10
0 Replies

5. UNIX for Advanced & Expert Users

logout script common for both Mac and Linux?

hi all , I need to run few commands on user logout. A non-root user should be able to edit that script which runs after logout. I need to make the solution both all Linux versions as well as Mac. Can any body help me in this regard. (0 Replies)
Discussion started by: harsha10
0 Replies

6. OS X (Apple)

Login/Logout script

Dear readers I use SnowLeopard 10.6.2 and need to do some special tasks at login and logout of an sepcific user. My problem is, how do I send a string "login" respectively "logout" from computer "A", where the login/logout script runs, to computer "B" where some other tasks need to be done. ... (3 Replies)
Discussion started by: tthaler
3 Replies

7. Shell Programming and Scripting

How to run script on logout ?

Hi Everybody, I want to run my own script on logout , i can use .bash_logout file... problem is this will work only for that particular user... i want to know the common file... so that script wil run for all the user... 2. How to run script on Shutdown ? Thanks in advance Anitha (4 Replies)
Discussion started by: anisn2002
4 Replies

8. Red Hat

Need Script to ZIP/SAVE & then DELETE Log file & DELETE ZIPS older than 12 months

ENVIROMENT Linux: Fedora Core release 1 (Yarrow) iPlanet: iPlanet-WebServer-Enterprise/6.0SP1 Log Path: /usr/iplanet/servers/https-company/logs I have iPlanet log rotation enabled rotating files on a daily basis. The rotated logs are NOT compressed & are taking up too much space. I... (7 Replies)
Discussion started by: zachs
7 Replies

9. Shell Programming and Scripting

Login, excute command, logout Script Help

Good Evening all, After spending the last week or so reading many posts I decided to register and join in. This is my first post on the forum so please forgive me as im new to this, Im after some help in throwing together a quick basic script without using expect to change the password on several... (4 Replies)
Discussion started by: mutley2202
4 Replies

10. SCO

Logout automatically when exiting a script

Hi, I am using SCO Unix. I write a script to execute a program by calling exec program The script will check the program is still there or not, if not, then it will exit the script by calling exit So if I press DEL to quit the program, the script will exit, but it will logout... (6 Replies)
Discussion started by: dannychan
6 Replies
getty(1M)						  System Administration Commands						 getty(1M)

NAME
getty - set terminal type, modes, speed, and line discipline SYNOPSIS
/usr/lib/saf/ttymon [-h] [-t timeout] line [ speed [ type [linedisc]]] /usr/lib/saf/ttymon -c file DESCRIPTION
getty sets terminal type, modes, speed, and line discipline. getty is a symbolic link to /usr/lib/saf/ttymon. It is included for compati- bility with previous releases for the few applications that still call getty directly. getty can only be executed by the super-user, (a process with the user ID root). Initially getty prints the login prompt, waits for the user's login name, and then invokes the login command. getty attempts to adapt the system to the terminal speed by using the options and arguments specified on the command line. Without optional arguments, getty specifies the following: The speed of the interface is set to 300 baud, either parity is allowed, NEW- LINE characters are converted to carriage return-line feed, and tab expansion is performed on the standard output. getty types the login prompt before reading the user's name a character at a time. If a null character (or framing error) is received, it is assumed to be the result of the user pressing the BREAK key. This will cause getty to attempt the next speed in the series. The series that getty tries is determined by what it finds in /etc/ttydefs . OPTIONS
The following options are supported: -h If the -h flag is not set, a hangup will be forced by setting the speed to zero before setting the speed to the default or a specified speed. -t timeout Specifies that getty should exit if the open on the line succeeds and no one types anything in timeout seconds. -c file The -c option is no longer supported. Instead use /usr/sbin/sttydefs -l to list the contents of the /etc/ttydefs file and perform a validity check on the file. OPERANDS
The following operands are supported: line The name of a TTY line in /dev to which getty is to attach itself. getty uses this string as the name of a file in the /dev directory to open for reading and writing. speed The speed argument is a label to a speed and TTY definition in the file /etc/ttydefs. This definition tells getty at what speed to run initially, what the initial TTY settings are, and what speed to try next, (should the user press the BREAK key to indicate that the speed is inappropriate). The default speed is 300 baud. type and linedisc These options are obsolete and will be ignored. FILES
/etc/ttydefs ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWcsr | +-----------------------------+-----------------------------+ SEE ALSO
ct(1C), login(1), sttydefs(1M), ttymon(1M), ioctl(2), attributes(5), tty(7D) SunOS 5.10 14 Sep 1992 getty(1M)
All times are GMT -4. The time now is 02:41 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy