reboot

Multiple Alarms Restart After Boot

≡放荡痞女 提交于 2019-12-23 02:35:09
问题 I'm setting multiple alarms so they can be repeated on specific days. Now I have heard that Android doesn't save the alarms on reboot. I have also read that BroadcastReceiver should be used when BOOT_COMPLETED to reschedule all the alarms. But how do I tell the BroadcastReceiver to reschedule alarms after reboot if I have 5 alarms per day = around 35 alarms scheduled on different days. Do I need to store them in the database or? How do I store them? Or is the BOOT_COMPLETED all I need? Is

How do I detect shutdown/reboot from linux app [duplicate]

試著忘記壹切 提交于 2019-12-22 13:59:29
问题 This question already has answers here : how to detect Linux shutdown/reboot (2 answers) Closed 6 months ago . I have an application written in C which runs as a daemon and needs to send something through RS232 when system is in shutdown or reboot state, and it needs to distinguish between these two. So my idea is: In my application script /etc/init.d/my_app in "stop" case of my script, I will run /sbin/runlevel command to get current runlevel: 0 - shutdown state 6 - reboot state then I will

Silent Windows Installer installer without rebooting automatically

坚强是说给别人听的谎言 提交于 2019-12-22 04:28:17
问题 Currently I have an MSI which performs a major upgrade, and it is launched as: msiexec.exe /i installer.msi /qn REBOOT=ReallySuppress My question is regarding that particular property REBOOT=ReallySuppress : does this mean it will not restart the system but will do proper changes (if applied) when user reboot her system manually? Or will it simply ignore those things that require to restart the system? 回答1: The installer performs all the operations. The value ReallySuppress of REBOOT property

Initiating a Phonegap plugin after device restart

浪子不回头ぞ 提交于 2019-12-21 08:00:13
问题 I am in the process of developing a hybrid Phonegap app for Android. The app uses just the one plugin which I am developing as well. The plugin does three things Watches for geo-location changes (both foreground and background) Sets up a half-hourly alarm to perform certain periodic tasks Listens for push messages. I use the pushy.me service and the code I use follows their documentation. I had implemented the code to get the application to tune in to device reboots with some trepidation but

How to restart Linux from inside a C++ program?

混江龙づ霸主 提交于 2019-12-20 19:45:21
问题 I have a Qt 4 GUI where I need to have a option in a drop-down menu that allows the user to choose to restart the computer. I realize this might seem redunant with the ability to restart the computer in other ways, but the choice needs to stay there. I've tried using system() to call the following: a suid-root shell script a non-suid shell script a suid-root binary program and all of them just cause reboot: must be superuser to be printed. Using system() to call reboot directly does the same

Setting environment variables requires reboot on 64-bit

蹲街弑〆低调 提交于 2019-12-18 12:46:45
问题 I am working on an installer using Wix 3.5 that needs to set the system PATH environment variable. This is how I am setting the environment variable: <Directory Id="DirectoryName"> <Component Id="ComponentID" Guid="{BE20AF67-5943-4AF4-BE66-226E2D4B844F}"> <Environment Id="EnvironmentID" Name="PATH" Action="set" Value="the path" Part="last" Separator=";" System="yes" /> </Component> </Directory> This seems to be working on 32-bit systems without requiring a reboot for the changes to be

how to do a linux reboot from php file

穿精又带淫゛_ 提交于 2019-12-18 06:36:19
问题 I have a user brftv on my linux system and I have www-data that runs the nginx. from the terminal I can let my brftv user run sudo /sbin/reboot and it works fine since I added the following to my /etc/sudoers file's "#user privilege specification" section: brftv ALL=NOPASSWD: /sbin/halt, /sbin/reboot, /sbin/poweroff www-data ALL=NOPASSWD: /sbin/halt, /sbin/reboot, /sbin/poweroff But when my php file runs the following code, nothing happens exec('nohup sudo -u brftv /sbin/reboot'); I added the

how to do a linux reboot from php file

删除回忆录丶 提交于 2019-12-18 06:36:14
问题 I have a user brftv on my linux system and I have www-data that runs the nginx. from the terminal I can let my brftv user run sudo /sbin/reboot and it works fine since I added the following to my /etc/sudoers file's "#user privilege specification" section: brftv ALL=NOPASSWD: /sbin/halt, /sbin/reboot, /sbin/poweroff www-data ALL=NOPASSWD: /sbin/halt, /sbin/reboot, /sbin/poweroff But when my php file runs the following code, nothing happens exec('nohup sudo -u brftv /sbin/reboot'); I added the

Android AlarmManager after reboot

▼魔方 西西 提交于 2019-12-17 04:21:52
问题 I have a set of alarms that I need to keep after reboot. I've tried using on an boot receiver but they won't start again. I'm not sure if I understand the boot receiver and how to then restart all the alarms. I already have one receiver for my notifications, but don't know whether I can use the same receiver or if I need a new one? Could anyone point me to any good tutorials or help me out? Cheers Code : DatabaseHandler db = new DatabaseHandler(this); List<UAlarm> alarms = db.getAllAlarms();

How do I prevent Windows from performing installations until a reboot occurs?

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-14 04:20:54
问题 I am testing installation scripts and must put Windows into a state that a reboot is pending from another installation. I have read how to test whether a reboot is needed. A proper way to set the need is not clear. 回答1: The honest answer: I don't know for sure . There are a lot of different registry locations that indicate that a reboot is necessary. I just tried to make an ad-hoc list here: How do I reference the Reboot Pending Property in Burn (WiX). I am not sure what mechanism uses them