06-19-2005
Suspending jobs (CTRL+Z) with a twist
Hi,
Say for example I'm doing a very large scp transfer (which I am) and I keep stopping it with CTRL+Z because other people on my network need the bandwidth too. I can restart it no problem with fg but only if I dont reboot or anything in between.
My question is... rather than stop/suspend a task with CTRL+Z can I somehow dump some data into a file than can be called after such a thing as reboot meaning my task can pick up where it left off? Did that make any sense lol...
Basically, can I stop a task and restart it after a reboot whilst maintaining the integrity of the data?
Thanks
9 More Discussions You Might Find Interesting
1. AIX
I wrote a ksh script for Helpdesk. I need to know how to disable ctrl-c,ctrl-z,ctrl-d..... so that helpdesk would not be able to get to system prompt :confused: (6 Replies)
Discussion started by: wtofu
6 Replies
2. Shell Programming and Scripting
Hi there,
I'm using HP-UX 11 machine. I am running a script, thats gonna take a long time to execute. When I press ctrl-c to come out of my script, I have to catch that signal(ctrl-c) and display that ctrl-c had been pressed. How can I do it.
Thanks in advance (2 Replies)
Discussion started by: sendhilmani123
2 Replies
3. Shell Programming and Scripting
i need to execute 5 jobs at a time in background and need to get the exit status of all the jobs i wrote small script below , i'm not sure this is right way to do it.any ideas please help.
$cat run_job.ksh
#!/usr/bin/ksh
####################################
typeset -u SCHEMA_NAME=$1
... (1 Reply)
Discussion started by: GrepMe
1 Replies
4. Shell Programming and Scripting
H! I have written script where it need to invoke the perl script in background, then write the pid in temp file then bring back the job to foreground. whenever the Ctrl-C or Ctrl-Z is pressed in the script has to exit and prompt should be dispalyed. but this script causing exit from shell session... (2 Replies)
Discussion started by: jramesh1
2 Replies
5. Shell Programming and Scripting
Hello,
I am running GNU bash, version 3.2.39(1)-release (x86_64-pc-linux-gnu). I have a specific question pertaining to waiting on jobs run in sub-shells, based on the max number of parallel processes I want to allow, and then wait... (1 Reply)
Discussion started by: srao
1 Replies
6. Shell Programming and Scripting
Hi,
while executing shell script, in the middle of the process, if we kill the shell script( ctrl+z or ctrl+c), script will be killed and the files which using for the script will be in the folder.
How to handle those scenarios. Is there any possibilities, if user breaks the script, I need to... (3 Replies)
Discussion started by: ckchelladurai
3 Replies
7. UNIX for Dummies Questions & Answers
Hi friends,
I am trying to add a newline char ('\n') between the query and the commit statement in the following shell script.
#! /bin/sh
echo "select * from tab; commit;" > data.sql
I have tried typing in "Ctrl-V + Ctrl-J" combination which has inserted ^@ (NUL) character but the commit... (1 Reply)
Discussion started by: royalibrahim
1 Replies
8. Shell Programming and Scripting
Hi..!
I'm stuck with my automation of starting a process and keeping it running even after the current ssh session has exited..
So i'm trying to use command 'screen'. which is doing exactly what i wanted, But the problem is automation of the same.
i will have to press Ctrl+a and Ctrl+d for... (2 Replies)
Discussion started by: chandana hs
2 Replies
9. Shell Programming and Scripting
I have multiple jobs and each job dependent on other job.
Each Job generates a log and If job completed successfully log file end's with JOB ENDED SUCCESSFULLY message and if it failed then it will end with JOB ENDED with FAILURE.
I need an help how to start.
Attaching the JOB dependency... (3 Replies)
Discussion started by: santoshkumarkal
3 Replies
LEARN ABOUT FREEBSD
reboot
REBOOT(8) BSD System Manager's Manual REBOOT(8)
NAME
reboot, halt, fastboot, fasthalt -- stopping and restarting the system
SYNOPSIS
halt [-lnpq] [-k kernel]
reboot [-dlnpq] [-k kernel]
fasthalt [-lnpq] [-k kernel]
fastboot [-dlnpq] [-k kernel]
DESCRIPTION
The halt and reboot utilities flush the file system cache to disk, send all running processes a SIGTERM (and subsequently a SIGKILL) and,
respectively, halt or restart the system. The action is logged, including entering a shutdown record into the user accounting database.
The options are as follows:
-d The system is requested to create a crash dump. This option is supported only when rebooting, and it has no effect unless a dump
device has previously been specified with dumpon(8).
-k kernel
Boot the specified kernel on the next system boot. If the kernel boots successfully, the default kernel will be booted on successive
boots, this is a one-shot option. If the boot fails, the system will continue attempting to boot kernel until the boot process is
interrupted and a valid kernel booted. This may change in the future.
-l The halt or reboot is not logged to the system log. This option is intended for applications such as shutdown(8), that call reboot
or halt and log this themselves.
-n The file system cache is not flushed. This option should probably not be used.
-p The system will turn off the power if it can. If the power down action fails, the system will halt or reboot normally, depending on
whether halt or reboot was called.
-q The system is halted or restarted quickly and ungracefully, and only the flushing of the file system cache is performed (if the -n
option is not specified). This option should probably not be used.
The fasthalt and fastboot utilities are nothing more than aliases for the halt and reboot utilities.
Normally, the shutdown(8) utility is used when the system needs to be halted or restarted, giving users advance warning of their impending
doom and cleanly terminating specific programs.
SEE ALSO
getutxent(3), boot(8), dumpon(8), nextboot(8), savecore(8), shutdown(8), sync(8)
HISTORY
A reboot utility appeared in Version 6 AT&T UNIX.
BSD
October 11, 2010 BSD