设置 /etc/rc.local 和 /root/autostart.sh 的自启动机制
This commit is contained in:
		
							parent
							
								
									fe2da5d767
								
							
						
					
					
						commit
						c27c5c235d
					
				| @ -34,6 +34,15 @@ sed -i "s/^PermitRootLogin yes/#PermitRootLogin yes/g" /etc/ssh/sshd_config | |||||||
| # emacs /etc/ssh/sshd_config | # emacs /etc/ssh/sshd_config | ||||||
| service sshd restart | service sshd restart | ||||||
| 
 | 
 | ||||||
|  | echo ">>> set autostart" | ||||||
|  | touch /etc/rc.local | ||||||
|  | chmod +x /etc/rc.local | ||||||
|  | echo "#!/bin/bash" | ||||||
|  | echo "exec /root/autostart.sh" | ||||||
|  | echo "exit 0" | ||||||
|  | touch /root/autostart.sh | ||||||
|  | chmod +x /root/autostart.sh | ||||||
|  | 
 | ||||||
| echo ">>> configure locales: install all-locales, default to zh-CN.UTF-8" | echo ">>> configure locales: install all-locales, default to zh-CN.UTF-8" | ||||||
| dpkg-reconfigure locales | dpkg-reconfigure locales | ||||||
| 
 | 
 | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user