CPP手艺人

导航切换

联系电话:
18906272588

  • 首页
  • 网站优化
  • 口碑营销
  • 微信开发
  • 整站优化
  • 新闻中心
  • SEO内容优化
  • 首页
  • 网站优化
  • 关键词优化
  • 口碑营销
  • 微信开发
  • 网站建设
  • 整站优化
  • SEO内容优化
  • 网站优化
  • 网站建设
  • 微信开发
  • 关键词优化
CPP手艺人
当前位置: 主页 > 百度SEO工具

如何让vps不待机_1

作者:CPP手艺人 来源: CPP手艺人   日期:2026-12-01 19:26:50

如何让VPS不待机

VPS(Virtual Private Server,何让虚拟专(zhuan)用服务器)是一种虚拟化的计算(suan)资源,可以为用户提供独立(li)的待机操作系统和硬件环境,在实际使用过程中,何让我们可能会遇到需要(yao)让VPS不(bu)待机的待机情(qing)况,例如在远程桌面连(lian)接时,何让或者在进行某些需要保持系统运行的待机操作,那么(me)如何实现让VPS不待机呢?何让本文将详细介绍几种方法。

如何让vps不待机_1

如何让vps不待机_1

修改电源管理设置

1、待机临时禁用休眠功能

如何让vps不待机_1

在Windows系统中(zhong),何让可以通过以下步骤禁用休眠功能:

a. 打(da)开“控制面板”。待机

b. 点击“硬件和声音”。何让

c. 点击“电源选项”。待机

d. 在左侧菜单中选择“更改计算机睡眠时间”。何让

e. 将“关闭显示器”和“进入睡眠状态”设置为(wei)“从不”。待机

f. 点击“保存更改”。何让

2、修改注册表

在Linux系统中,可以通过修改注册表来禁止休眠功能,创建一个名为disable_hibernate.reg的注册表文(wen)件,内容如下:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlPowerPowerSettings7bc4a363-da86-4464-bafb-ff5bb81db4be238C9FA8-0AAD-41ED-83F4-97BE242C8F20]

"Attributes"=dword:00000001

以管理员身份运行命令提示符,执行以下(xia)命令导入注册表文件(jian):

reg import disable_hibernate.reg

使用命令行工具

1、关闭休眠功能(Windows)

在Windows系统中,可以使用powercfg命令来关闭休眠功能,打开命令提示符,输入以下命令:

powercfg /h off

2、关闭休眠功能(Linux)

在Linux系统中,可以使用systemctl命令来关闭休眠功能,创建一个名(ming)为disable_hibernate.service的服务文件,内容如下:

[Unit]

Description=Disable Hibernate mode for system shutdown and reboot events (for Debian systems only)

After=syslog.target network.target remote-fs.target nss-lookup.target timesync.target watchdog.target apt-daily.timer unattended-upgrades.timer udev-trigger startlimitd.service automount-nfs.service iscsid.service inetutils-resolvconf.service avahi-daemon.service avahi-autoipd.service avahi-dnsconfd.service cups-cleanup-timer lightdm.service dbus-daemon dbus-userspace.service gpm.service sshd.service systemd-networkd-wait-online.service systemd-timesyncd.service apparmor.service auditd.service nagios3-checkpoints.service rsyslog.service libvirtd.service systemd-tmpfiles-setup.service systemd-journald.service systemd-logind.service systemd-udevd.service systemd-random-seed.service systemd-timesyncd@systemd-timesyncd.service systemd-timesyncd@systemd-timesyncd-pathfinder.service systemd-timesyncd@systemd-timesyncd-pathfinder-wait.service systemd-timesyncd@systemd-timesyncd-pathfinder-wait.service systemd-timesyncd@systemd-timesyncd-pathfinder-wait2.service systemd-timesyncd@systemd-timesyncd-pathfinder2.service systemd-timesyncd@systemd-timesyncd2.service systemd-timesyncd@systemd-timesyncd2.service systemd-timesyncd@systemd-timesyncd2@sockets.service systemd-timesyncd@sockets2.service systemd-timesyncd@sockets3.service systemd-timesyncd@sockets3@sockets3.service systemd-vfsmount@procfs.service systemd-tmpfiles@devtmpfs.service systemd-tmpfiles@runtmpfs.service systemctl enable –now hibernateonboot.timer disable_hibernate@%I service name="Hibernate on Boot" enabled="yes" description="Disable Hibernate mode for system shutdown and reboot events (for Debian systems only)" type="oneshot" startdelay="1min" action="/usr/lib/systemd/system/disable_hibernate@%I.sh" after="networking">

创建一个(ge)名为disable_hibernate@%I.sh的脚本文件,内容如下:

!/bin/sh -e BEGIN INIT INFO Provides: disable_hibernate@%IRequired-Start: $remote_fs $syslog $network $named $time $tmpfs $mailslot $cron $anaconda $pulse $syslogrotate $tcpdump $acpid $gpm $rsyslog $avahi $auditd $firewalld $input$input$netfilter$iptables$ip6$ip6tables$arpwatch$bluetooth$bspwm$conntrack$cups$cpufreq$cpuspeed$devicemapper$debootstrap$dhcpcd$directio$diskstats$dunst$dropbear$execstart$fail2ban$firewallmark$filesystems=${ locale}.UTF8 $firewalls $gdm3 $gnome_session $htop $iwd $keepawake $lesslockscreen $lxpolkitlock $netcat $networkmanager $ntpd $open='open'box $parted $pciutils $pulseaudio $rcctl $(psmisc | grep tty) $(psmisc | grep serial) $(psmisc | grep xterm) rrdtool screen saver stopxserver ureadahead udev usermod useradd userdel vim visudo wpa_supplicant wpa_action wpa_cli wpa_passphrase wpa_supplicant wpa_state wakealarm xinit xloadavg xsetroot xterm zsh top man chkconfig sysctl depmod modprobe modinfo free ramfree swapfree inodefree blockcount blocksize iostat iotop iftop netstat netstat tcpdump nmap uptime whowhois whoami id ps pstree procstat vmstat yum update yum list installed yum history last reboot epel release repolist yum clean all yum makecache fast install yum remove epel* yum groupinstall "Development Tools" yum install epel* yum install kernel headers kernel source rpmdevtools yum install python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 python34 yum install epel* kernel headers kernel source rpmdevtools yum install python34 yum install epel* kernel headers kernel source rpmdevtools yum install python34 yum install epel* kernel headers kernel source rpmdevtools yum install python34 yum install epel* kernel headers kernel source rpmdevtools yum install python34 yum install epel* kernel headers kernel source rpmdevtools yum install python34 yum install epel* kernel headers kernel source rpmdevtools yum install python34 yum install epel* kernel headers kernel source rpmdevtools yum install python34 yum install epel* kernel headers kernel source rpmdevtools yum install python34 yum install epel* kernel headers kernel source rpmdevtools yum install python34 yum install epel* kernel headers kernel source rpmdevtools yum install python34 yum install epel* kernel headers kernel source rpmdevtools yum install python34 yum install epel* kernel headers kernel source rpmdevtools yum install python34 yum install epel* kernel headers kernel source rpmdevtools yum install python

  • 微信开发
  • APP开发
  • 百度SEO工具
  • SEO诊断
  • AI运营推广
  • 关键词优化
地址:上海市普陀66号
服务电话:18933593942
Copyright © 2012-2018 CPP手艺人 版权所有 备案号:  

学校官方微信

联系我们

微博
客服
友情链接: 重庆南川思驰网络科技有限公司宜城来界网络科技有限公司兴化实胜网络科技有限公司临海用运网络科技有限公司烟台禄润网络科技有限公司凯里大贸网络科技有限公司廊坊寿祥网络科技有限公司 长沙创新高级中学秋莱网络中国书画考级