Red Hat :: Shutdown - System Goes Down Before My Rc Script Execute

Apr 1, 2010

Tested on RedHat entreprise 5.5, 5.4, 5.3 I would like to stop my db (not oracle) when the system shutdown or reboot. I have wrote my script for init.d

Here is the head :

The problem is : shutdown -r stop the system before my K script execute. I have not my "blabla" in /tmp/mystop.log

In fact the scritp is for database startup and database shutdown manually it works I mean : /etc/init.d/mystop stop ; /etc/init.d/mystop start So I truncated the scritp until I only get echo "blabla"

This work idealy under HPUX, AIX, and I think I'm missing something "special" for Redhat. I'm quite sure it was ok with redhat 8 and ES 3.0.

View 10 Replies


ADVERTISEMENT

Ubuntu :: Execute A Script On X Shutdown?

Mar 27, 2010

I would like to be able to execute a script every time X is shut down (e.g., by Ctrl+Alt+Backspace), namely, logout. Is this possible? If it is, in what file do I put the command/script?

View 9 Replies View Related

Ubuntu :: Execute Tasks List Before Shutdown

Aug 10, 2010

When I shut down my computer I want to show some pending tasks that I have to do before leaving the office... I did a local application to manage those tasks, so basically I just want to run a command, and shut down after I kill the app executed. I have already tried with these options:

* /etc/gdm/PostSession/Default --> this works only when I select LogOut option instead Shutdown.

* /etc/rc0.d/K01mycustomscript --> execute script after X is killed

* $HOME/.bash_logout --> This looks like does nothing.

* ./app-to-run && sudo shutdown -h now --> Don't like it for 2 reasons, prompts for sudo password, and can't use my laptop shutdown button.

How could I modify Shutdown dialog ? should I recompile Gnome ? Options? I am using Ubuntu 10.04

View 5 Replies View Related

Ubuntu :: Execute Python Code Before Shutdown

Dec 2, 2010

I have written a backup script backing up the data I have worked during the day with rsync and sends me a log in my email. now it works perfect but i want to execute it each time i shutdown my computer in the evening not during reboot or logout.It seems that i can not run it by putting it in init.d and softlinking in rc0.d as K00backup. I think it is because script uses many services like python or smtplib, gnome-keyrings that in that time might have been already shutdown.

View 2 Replies View Related

CentOS 5 :: Where To Put Commands To Execute Just Before Shutdown / Logoff?

Mar 3, 2010

Where can I put commands which should be executed just before

- logoff

- shutdown

I think there must be somewhere an opposite script to

.initrc
or
.bashrc

View 5 Replies View Related

Debian Programming :: Execute System Command Using Qt

Feb 19, 2014

I was writing code to execute system command, using GDM3 an logged in as root (just commented line #auth required

pam_succeed_if.so user != root quiet_success , in /etc/pam.d/gdm3).

When i execute:

Code: Select allvoid criarWindowsDialog::on_pushButton_2_clicked() {
    ui->commandTextEdit->append("Processo iniciado ...");
    QProcess processo;
    QString comando;
    QStringList args;
    QString fullCommand;
    QString stdOut;
    QString stdError;

[CODE]..

View 0 Replies View Related

Ubuntu :: Execute System Command With Perl?

Jun 13, 2011

i want to execute system command with perlm but it gives me error.

command is wmic client. here it is

#!/usr/bin/perl
open (EP, "/home/user/Templates/domainpc.log");
while (<EP>) {
chomp;

[Code]....

View 1 Replies View Related

General :: Shutdown -k +2 System Going Down?

May 10, 2009

I tried the above command on my pc. It broadcasts the message passed , but I noticed one thing that during this time( 2min) normal users are not allowed to login onto the terminal.

View 2 Replies View Related

Programming :: System Administrator Wants To Change The Privilege* Only To Users 1, 2 And 3 To Execute The File /bin/xxx?

May 1, 2010

due to an exercise in Operating Systems I have to do the following: There are 6 users, user1, user2 ... user6 with home directories /users/user1 ... users/user6. User1 to user3 belong to group1, user4 to user6 belong to group2. The System Administrator wants to change the privilege* only to users 1, 2 and 3 to execute the file /bin/xxx. Which are the commands he has to type in order to achieve the previous?*I'm not sure if this is the right translation.What I have come till now is: Code: $ chgrp group1 <name_of_file> but it seems too simple to be right.

View 1 Replies View Related

General :: Setup A System To Allow Normal Users To Execute A Command Without Using Sudo?

Jan 5, 2011

I am trying to setup a system to allow normal users to execute a command without using sudo. Is this possible?

View 6 Replies View Related

General :: Command To Compile And Execute Fortran Program On System Machine?

Apr 8, 2010

Command to compile n execute a Fortran program on a Linux machine

View 6 Replies View Related

Fedora :: System Shutdown Only Logs Out

Feb 14, 2011

I currently run kernel 2.6.34.7-66.fc13.i686 (sort of). When I select from the Gnome menu System -> Shutdown and select Shutdown from the dialog, my system only logs out, presenting me with the greeting screen. While this is a minor problem and I rarely shutdown my machine, it is mildly disconcerting.I have dropped back to 2.6.34.7-63.fc13.i686 and that shutdowns properly using this method. (Also, 2.6.34.7-61.fc13.i686 works properly). I can imagine that it might close some security issue in which an unauthorized user is able to halt the entire machine. Especially if this is something that will continue in future releases of the kernel.

View 5 Replies View Related

Ubuntu :: System Shutdown Without Any Permission

May 4, 2010

From couple of mins my system shutdowned without my permission I thought I'm infected or something because I installed aMSN so I thought it's because of it, but I checked my syslog and found this:

May 5 00:01:30 spuny-laptop kernel: [ 2441.497050] CE: hpet increasing min_delta_ns to 15000 nsec
May 5 00:17:01 spuny-laptop CRON[1912]: (root) CMD ( cd / && run-parts --report /etc/cron.hourly)
May 5 00:37:32 spuny-laptop pppd[1560]: Protocol-Reject for unsupported protocol 0xac05
May 5 00:38:15 spuny-laptop pulseaudio[1426]: ratelimit.c: 2 events suppressed
May 5 00:48:06 spuny-laptop kernel: [ 5237.586974] hda-intel: IRQ timing workaround is activated for card #0. Suggest a bigger bdl_pos_adj.
May 5 00:50:22 spuny-laptop kernel: [ 5373.683347] Critical temperature reached (100 C), shutting down.
May 5 00:50:22 spuny-laptop kernel: Kernel logging (proc) stopped.

Temperature reached is that what cause system halt? Also when I press ctrl+alt+Fn I see blank screen why is that?

View 4 Replies View Related

Ubuntu :: Unable To Shutdown The System?

Sep 10, 2010

I am using Ubuntu 10.04. From last 3-4 days, after updating, I am not able to shutdown the system. I try to use command, but behavior is same Whenever I try to shutdown the system, it exits from desktop environment and a white screen displays on screen. And nothing happened. One time I did wait for 1/2 hr, but system dont seems to power down.

View 4 Replies View Related

Ubuntu :: System Not Shutdown For One Click

Aug 8, 2011

my system needs two times shutdown button selection for shutdown , after doing second its getting shutdown , for single selection its not

View 1 Replies View Related

General :: System Beep On Shutdown?

Aug 19, 2009

after installing linux mint 7, I have been getting one beep on shutdown, a google search on this came back as a ram problem...but then i ran across a bunch of posts on ubuntu forums about one beep on shutdown, with an older version of ubuntu, grep does return some paramter errors, but in the mint bug report page those are listed as : benign ignore. it doen't bother me in the least, as long as it isn't a warning of impending hardware failure.

View 5 Replies View Related

Red Hat / Fedora :: Shutdown System Through Crontab?

Jun 11, 2009

I am practicing on "crontab" and am able to get system status in time but I want to shut my system through crontab.#15 12 11 06 thu init 0

View 1 Replies View Related

General :: Add Shutdown Under System Toolbar?

Apr 30, 2010

I'm running Ubuntu 10.04, and I like to logout or shutdown or restart my system with system->shutdown just as in Fedora, but it's not there. How can I add this, the only way that I have been using is through the terminal or Crtl-Alt-D, which doesn't has Logout option but Hibernate.

View 2 Replies View Related

Debian :: Execute Command Mactime In Order To Control Changes Made To The File System?

Apr 23, 2011

I am trying to execute command mactime in order to control changes made to the file system, but I am getting an error. I am running the shell as root, and it is the first time I run the command in this system - Debian Squeeze up to date. The I/O is as follows:

# mactime 3/1/2011
cannot exec /bin/date: No such file or directory
cannot exec /bin/hostname: No such file or directory
cannot exec /bin/uname -n: No such file or directory
Cannot open /var/cache/tct/data/Amnesiac/body: No such file or directory

The first three lines of output are the ones that are worrying at the moment; I am not concerned with the last. Although error messages suggest the programs date, hostname and uname do not exist in /bin directory, they are available as shown by

[Code]...

View 3 Replies View Related

Debian :: Slow Shutdown / Restart Of System

Sep 21, 2015

As the object, when I shutdown or restart my system, this will stuck on black screen for about 30/40 second and then continue...

My system is debian testing with kernel 4.1.0-2

View 8 Replies View Related

Debian :: System Rebooting On Shutdown -h Now Command

Aug 17, 2011

I am running Debian Squeeze on an Intel DH55TC motherboard. When I issue a shutdown command
shutdown -h now

The system goes shutting down. Eveything looks fine, and the main console shows all process being stopped. In the end it says "System will now halt". Then a few seconds later, it restarts. It is unclear what is causing this, because nothing is written to the screen. It just goes blank and starts rebooting. Looking afterwards in syslog doesn't show anything also.

View 14 Replies View Related

Fedora :: Unable To Shutdown From System Menu

Jan 26, 2010

When I try to shutdown or reboot from the system menu in Fedora 12, I am returned to the logon prompt. I am able to shutdown and reboot from a terminal window by issuing the shutdown command as the root user.

View 6 Replies View Related

Fedora :: No System Shutdown Sound And Screen

Apr 4, 2010

Does fedora 12 have logout sound and wallpaper? I don't get a logout music and the logout screen is blank.

View 2 Replies View Related

Fedora :: System Keeps Freezing During Start Up And Shutdown?

Jul 21, 2011

I've just installed F15 KDE Edition, and as the title tells, I need to keep pressing F2 and/or Enter to make the system go through the boot up process, otherwise it freezes as long as i keep it without my interference !! and then it takes relatively long time to start the GUI, and when I switch to the console (using ALT + CTRL + F3 for example) and try to write the login or the password, there seem to be some 'bouncing' effect, that if I'm to write the login 'root', I get something like 'rrooott' ... however, this doesn't happen in the GUI .....

I have a multiboot system, with Windows7 and Linux Mint (based on ubuntu 10.4) installed along side. While Windows7 doesn't have any problem with my hardware, Linux mint has also some issues that cause the performance of media players to degrade (sound and video tearing) and cause repeated freezes to some applications (a game actually, 'wesnoth') until I press a key or move the mouse.

I have AMD Athlon 7750 dual core 2.7 GHz system, with 3GB DDR2 800 Ram, and embedded ATI Radeon HD 3200 with about 512 shared memory.

one more thing, when I booted off the live image to run the install program, I booted into the video failsafe mode (not sure of the exact name, but I think you got it, no mode setting) and passed the option 'noapic', so I suppose this options are still passed whenever I boot mysystem, as I get the text version of the progress bar during startup, rather then the graphical fedora logo ( i.e no mode setting) ..

View 3 Replies View Related

OpenSUSE Install :: 11.4 - KDE 4.6 Hang On System Shutdown

Aug 23, 2011

I am new to opensuse, coming over from debian based systems. However I am having an issue in which my system will not power off on shutdown. Restarts just fine. i get a missing error during shutdown, but there is nothing to relate the error to on that line. Then the shutdown procedes to The System will be halted immediately then hangs. The keyboard powers off and then thats it. All fans are still running. I have searched extensively on this forum and google.

View 9 Replies View Related

General :: Correct Way To Shutdown System While Apt-get Still Running

Sep 9, 2011

What's the correct way to shutdown system while apt-get is still running? apt-get complains about unclean shutdown when I just shutdown computer.

View 2 Replies View Related

Ubuntu :: NIC Not Turned Off On System Shutdown / Sort It?

Feb 26, 2010

It appears I've got some strange driver problem.. When I shut down this computer, the NIC apparently doesn't go off. The LEDs next to the ethernet socket keep blinking, so does the LED on my ethernet switch.

I don't have this problem when using XP, only Karmic. That leads me to think that there's something wrong with the network driver. My NIC is on-board, the ASUS M3A32-MVP. According to System Info this is the Marvell 88E8056 PCI-E.
It seems like ASUS doesn't have the drivers on their website (anymore), because their website search returns empty handed. Also the motherboard product page doesn't appear to know it.

Anyone have any tips / ideas? I'm just unplugging the machine before turning it off now... as it appears to be disturbing the rest of my network

View 4 Replies View Related

Ubuntu :: Change System Shutdown Order

Oct 3, 2010

My Ubuntu file server sits under a desk and shares files with the network without a hitch, and in a perfect world I wouldn't ever need to shut it down (I reached 6 months uptime once). However, since it occasionally needs service, or additions and needs to be moved, I need to shut down.

The trouble is, the power management system is borked, so whenever I issue "sudo powerff now", the system halts, but the PSU stays on. I usually wait a few minutes after and flip the PSU switch, but I'm never sure if the system is already down.

Is there a way to reorder the way services shut down so that I put SSH last, and therefore know when the system is down when my session is disconnected? Is defaults.rc or whatever responsible for that?

View 3 Replies View Related

Ubuntu :: System Doesn't Stay Shutdown?

Nov 27, 2010

When I shut down the computer, it does not remain shut down. This is different from "restarting" the computer because when I "shutdown" the computer powers down, the fan and disks stop spinning for a second, and then everything starts again. When I "restart" the fan and disks remain spinning throughout the restart process.Further, the computer is dual booting with Windows XP Pro. If I shut down from Windows, the system remains shut down.

System Information:
Ubuntu 10.04 Lucid Lynx
kernel: 2.6.32-26-generic

[code]...

View 6 Replies View Related

Debian :: Complete System Freeze During Shutdown?

Apr 1, 2010

When I try to shut my PC down (press the shutdown button in KDE 4.3.4), the desktop quits, but the console screen does not appear (the CTRL+ALT+F1 screen). Well, technically speaking it appears but only a still (not blinking) cursor is shown, otherwise the whole screen is blank. This means that not only the X freezes but whole system, because the keyboard is unresponsive too. It happend multiple times now, and every time I reboot after such event, some kde rc files (amarokrc, kmailrc, etc...) get deleted due to the automated filesystem check (unclean umount), which means that I have to reconfigure these apps again.

My home partition is on a separate EXT2 partition (this way I have full r/w access from winxp) and every time this is the only one which gets corrupted. The system partition (which is EXT3) is always intact (no fsck starts on boot). I'm using Debian Squeeze by the way.

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved