Hot answers tagged

32

There is no better way to restart your server by using anything else than any those commands. shutdown is the most common way to stop your system. reboot is a wrapper round shutdown which does some harddisk maintenance (syncing and/or putting in standby mode and not really relevant). New versions of reboot (>2.74) will initiate shutdown if not in runlevel ...


28

You will need to modify the group policy that is applied to the servers. Open up the Group Policy Management Console and navigate to Computer Configuration >> Administrative Templates >> System and select "Display Shutdown Event Tracker." Disable that option.


15

For Red Hat systems, there is no functional difference between reboot and shutdown -r now. Do whatever is easier for you.


14

If you do not want to change via Polices you can always issue the shutdown command to avoid the question. shutdown /s /t 0 /s = shutdown /t = time till shutdown 0 = immediely


12

BINGO!!! Alright, here is how this was resolved: I referenced this artice for unmounting the datastore, https://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=2004605 Step 1: Manually unmount the datastore from the host with this command: esxcli storage filesystem unmount [-u UUID | -l label | -p path ] In ...


11

If the system has reached runlevel 0, it can be safely powered off. Not so many years ago, before ATX, you had to turn off a PC system by hand because it couldn't power down itself.


11

Shutdown is preferable because it allows you to specify the reason for the drastic action -- something you should always do. The message will be recorded in the log(s) for posterity. For example: shutdown -r now 'Kernel upgrade requires reboot' You can also perform a scheduled reboot -- by specifying something other than now as the reboot time: shutdown -...


9

Running the following as an elevated admin: reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Reliability" /v ShutDownReasonOn /t REG_DWORD /d 0 /f and then logging off and on again should to the trick. This is quicker than using group policies which you should use when you are in a domain and want to apply this change to many servers.


8

A graceful shutdown of Centos 6.x should be done by using the command as root: shutdown -h now This will attempt to stop all running services before shutting down the server gracefully. Using this command also prevents mySQL socket issues. Similarly, for a graceful reboot: reboot -h now You can read a previous answer about a similar question here: ...


8

It depends on how your configured your Virtual machines. If you have your VMs configured to 'Turn OFF', then shutting down the host OS would be close to equivalent to pulling the power from the VMs. If your VMs are configured this way, and you want them to safely shutdown, then you need to shut them down first. You could also use the other options like ...


7

I'm sure the OP has found the other answers useful but future readers may be interested in a powershell version. Works out of the box in 2008 or up, and maybe in 2003 if powershell is installed. if ( -Not (Test-Path 'registry::HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows NT\Reliability')) { New-Item -Path 'registry::...


6

The Procmon utility from Windows Sysinternals is capable of doing comprehensive logging of all processes during startup, logoff, and shutdown. For detailed information, read the Windows Sysinternals Administrator's Reference, section 2, chapter 4. There is a subsection titled Logging Boot, Post-Logoff, and Shutdown Activity on confiuguring the boot logging ...


6

Q. If my spot instance is automatically terminated due to my max bid being exceeded, is it a clean shutdown -- as if a user clicked Start>>Shutdown ? Or is it a hard shutdown -- as if someone just yanked out the power cord? It might be a clean shutdown, but it also might be a hard shutdown. Amazon's wording implies they try to make it clean but don't ...


6

This tip worked for me in the past, if you can disable ATS-Only: Cannot mount the VMFS5 datastore when using storage encryption appliances (2030416) I guess no VM are up in your case, but they need to be close to be able to run the command. Some storage encryption appliances may block certain SCSI commands, including ATS commands, sent from ESXi ...


5

There is no difference in them. Internally they do exactly the same thing: 1. reboot uses the shutdown command (with the -r switch). The shutdown command used to kill all the running processes, unmount all the file systems and finally tells the kernel to issue the ACPI power command. 2.init 6 tells the init process to shutdown all of the spawned ...


5

$ dpkg -S /sbin/shutdown sysvinit-core: /sbin/shutdown You probably "upgraded" to systemd, removing shutdown and friends. If so, you now need to do systemctl poweroff to shutdown the system. Why does systemd not provide an alias to shutdown? Why not indeed... EDIT: /sbin/shutdown should be available if you install the systemd-sysv package. It would be ...


5

Is there a well defined/known amount of time that a shutdown must take at the most? No.


5

If you take a look, in RHEL 7 both /sbin/shutdown and /sbin/reboot are actually just symlinks to systemd's systemctl command. So, use whatever you want. No functional difference as ewwhite told, not even in earlier RHEL releases which did not yet use systemd.


4

As far as i can see, you are having a cyclic dependecy. You are telling systemd to start PHP-fpm before Apache and at the same time after Apache. This cannot work the way you want it to. In your httpd.service file specify the following: Requires=mariadb.service php-fpm.service After=mariadb.service php-fpm.service The explanation of the options for ...


4

Shutdown.exe still ships with the new versions of Windows. Simply run: shutdown /i and the following prompt will appear, allowing you to shutdown/reboot 1 or more servers with a Reason comment:


4

You created your guest with virsh create (or its equivalent). This creates transient domains, which are deleted when they power off. To create persistent domains, use virsh define instead. These remain defined after they are powered off or destroyed, and can be started again at any time.


3

"/sbin" is not in default cron PATH. So you need to add it there. you can check it with: */2 * * * * /bin/echo "$PATH" > /home/myuser/my.log Result: [root@localhost vagrant]# cat my.log /usr/bin:/bin Also you can see it in the mail headers sent by cron: Content-Type: text/plain; charset=UTF-8 Auto-Submitted: auto-generated X-Cron-Env: <SHELL=/...


3

The fact you can't power down a 2012 server when a session is locked is probably by design. I faced a similar need and don't know any policy or registry change to allow that. I used a simple trick: I captured the power button event which simply run my favorite shutdown.exe with the desired parameters after a timeout. If you use the correct shutdown ...


3

Yes, If you rename or remove C:\Windows\WinSxS\pending.xml file, you could postpone update to next reboot. I advice renaming it. It may require changing the permissions and ownership of the file. I haven't tested it on running windows image, but I am sure it works when you interrupt windows boot. Boot into recovery mode or from windows installation disc (...


3

There are SuperMicro servers, which have battery inside. And there are SSDs with supercap, like Intel's PLI technology. Edit: After quick googling I found this internal UPS. It looks dated, but may very well still be in production.


3

Converting my comments/thoughts into an answer. It appears that you have given all of the students: Administrative control over all the computers. Anonymity by allowing them to all share the same admin account. This is probably a suboptimal configuration in a typical classroom setting. Although you claim that the students are not administrators on the ...


3

If you need to initiate commands on your (Ubuntu) Linux machines orchestrated centrally from another host, the tool of choice is usually ssh. This is not all that different if your orchestrator host is a Windows machine. Cygwin comes with OpenSSH's version of the client (and the server in the same package, but I certainly would recommend removing the server ...


2

The timer is part of the windows update service not the OS itself so you can stop it by stopping the service try net stop "windows update"that should do the trick. But this is a temp solution since the service will start again when you reboot later, I guess what you really want is forcing the Windows to do the restart at the update scheduling time, ...


2

Solved: It's CATALINA_OPTS not JAVA_OPTS. The HOWTOs are wrong. Reference: Tomcat Docs Regarding Profiler


2

It's probably not running because it's unable to find the binary. Without any error log though, that's just an assumption I'm making. Try adjusting the s3cmd part in your script to use its full path. I'm not sure how you installed s3cmd (either via yum or manually), but you can find out its full path by running which s3cmd.



Only top voted, non community-wiki answers of a minimum length are eligible