Sponsored Content
Full Discussion: async vs sync shells
Top Forums Shell Programming and Scripting async vs sync shells Post 17182 by LivinFree on Tuesday 12th of March 2002 02:38:41 AM
Old 03-12-2002
This sounds more like an issue with the database utility.
You could, however, write it in such a way that when the script begins, it places a "flag" file somewhere, say named something like "dont_run_again". Now, if someone tries to run this twice, it should check for the existance of this file, and quit without running if it finds it. Then, at the end of the original script, remove the file...
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Async or Sync I/O on NFS ?

Solaris 2.8 I know regular filesystems use Async I/O on Solaris 2.8. Does anybody know if NFS uses Sync I/O or Async I/O ? (1 Reply)
Discussion started by: marist89
1 Replies

2. Solaris

Async DNS request

Yes, really can't find anything about this. Can anyone suggest a way, how to do it? This is really what I need for. I need for may be list of system calls to read about or probably some C\C++ sources... Please, help... (1 Reply)
Discussion started by: LocalStorm
1 Replies

3. Programming

How to Write Linux Friendly Async Socket I/O

I am presently refactoring a windows deamon with an eye towards porting it to linux someday. Presently the application uses a single background thread and asynchronous socket I/O to implement FTP and HTTP clients in a single switch statement (2000 lines and 100 cases just for the switch... (3 Replies)
Discussion started by: siegfried
3 Replies

4. Solaris

Sync to Green vs. Separate Sync

Hi all....I have a Sun Ultra2 that I want to use with my PC monitor. I have purchased an adapter that does not work and I was told I need to change my video card setting (if I can) to Separate Sync.....my Monitor product number ends in 1343......I am running SunOS 5.7 ......anyone have any ideas? ... (0 Replies)
Discussion started by: psantinello
0 Replies

5. Solaris

Async-Signal-Safe versus MT-Safe

Hi, I am Solaris 9 developer and notice that the documentation does not provide a clear notion of the inherent concurrency in routines defined as "Async-Signal-Safe". Routines defined as "MT-Safe" obviously have the best level of concurrency, compared to normal "Safe" interfaces. I have... (1 Reply)
Discussion started by: tristan12
1 Replies

6. Red Hat

Difference between sync & async in nfs

Hi All.... This is related to exporting a file system through nfs. Just wanted to understand the significance of sync/async in nfs. We give this entry in /etc/export file. What is the difference between these two. Any hep is appreciated. Regards, Amol. (2 Replies)
Discussion started by: Amol21
2 Replies

7. Solaris

see if async i/o is enabled in Solaris 9

Hi guys. This may be a stupid question but I am trying to see if my Solaris 9 server has async i/o enabled... Is there a quick way to determine this? Thanks in advance. (1 Reply)
Discussion started by: jamie_collins
1 Replies

8. UNIX for Dummies Questions & Answers

Shells

Lets say my default shell is bash and then i load up csh and then ksh. How would i exit csh without exiting ksh? so basically i gone from bash > csh > ksh and i wish to close csh (2 Replies)
Discussion started by: Bill Thompson
2 Replies

9. Programming

Async webpage read

hi i need to asynchronous connect to webpage which has only text file. need to read its content, line by line using linux socket. any samples? (1 Reply)
Discussion started by: leo2008
1 Replies

10. AIX

Disable async IO at OS level

Hi , User claims that report refresh is taking longer time than usual time and asking us to disable async IO at OS level. 1 DB is running in this server This is prod server OS -- AIX My question is would there be an impact to database and server if we disable async IO in OS? is this... (4 Replies)
Discussion started by: Maddy123
4 Replies
SCRIPT(1)						    BSD General Commands Manual 						 SCRIPT(1)

NAME
script -- make typescript of terminal session SYNOPSIS
script [-adkpqr] [-F pipe] [-t time] [file [command ...]] DESCRIPTION
The script utility makes a typescript of everything printed on your terminal. It is useful for students who need a hardcopy record of an interactive session as proof of an assignment, as the typescript file can be printed out later with lpr(1). If the argument file is given, script saves all dialogue in file. If no file name is given, the typescript is saved in the file typescript. If the argument command is given, script will run the specified command with an optional argument vector instead of an interactive shell. The following options are available: -a Append the output to file or typescript, retaining the prior contents. -d When playing back a session with the -p flag, do not sleep between records when playing back a timestamped session. -F pipe Immediately flush output after each write. This will allow a user to create a named pipe using mkfifo(1) and another user may watch the live session using a utility like cat(1). -k Log keys sent to the program as well as output. -p Play back a session recorded with the -r flag in real time. -q Run in quiet mode, omit the start, stop and command status messages. -r Record a session with input, output, and timestamping. -t time Specify the interval at which the script output file will be flushed to disk, in seconds. A value of 0 causes script to flush after every character I/O event. The default interval is 30 seconds. The script ends when the forked shell (or command) exits (a control-D to exit the Bourne shell (sh(1)), and exit, logout or control-D (if ignoreeof is not set) for the C-shell, csh(1)). Certain interactive commands, such as vi(1), create garbage in the typescript file. The script utility works best with commands that do not manipulate the screen. The results are meant to emulate a hardcopy terminal, not an addressable one. ENVIRONMENT
The following environment variables are utilized by script: SCRIPT The SCRIPT environment variable is added to the sub-shell. If SCRIPT already existed in the users environment, its value is overwrit- ten within the sub-shell. The value of SCRIPT is the name of the typescript file. SHELL If the variable SHELL exists, the shell forked by script will be that shell. If SHELL is not set, the Bourne shell is assumed. (Most shells set this variable automatically). SEE ALSO
csh(1) HISTORY
The script command appeared in 3.0BSD. The -d, -p and -r options first appeared in NetBSD 2.0 and were ported to FreeBSD 9.2. BUGS
The script utility places everything in the log file, including linefeeds and backspaces. This is not what the naive user expects. It is not possible to specify a command without also naming the script file because of argument parsing compatibility issues. When running in -k mode, echo cancelling is far from ideal. The slave terminal mode is checked for ECHO mode to check when to avoid manual echo logging. This does not work when the terminal is in a raw mode where the program being run is doing manual echo. If script reads zero bytes from the terminal, it switches to a mode when it only attempts to read once a second until there is data to read. This prevents script from spinning on zero-byte reads, but might cause a 1-second delay in processing of user input. BSD
December 4, 2013 BSD
All times are GMT -4. The time now is 10:11 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy