ubuntu设置tightvncserver自动启动
来源:互联网 发布:网络综合布线公司转让 编辑:程序博客网 时间:2024/06/11 03:50
vi /etc/init.d/vnc#!/bin/bashPATH="$PATH:/usr/bin/"export USER="root"DISPLAY="1"DEPTH="24"GEOMETRY="1024x768"OPTIONS="-depth ${DEPTH} -geometry ${GEOMETRY} :${DISPLAY} -localhost". /lib/lsb/init-functionscase "$1" in start) log_action_begin_msg "Starting vncserver for user '${USER}' on localhost:${DISPLAY}" su ${USER} -c "/usr/bin/tightvncserver ${OPTIONS}" ;; stop) log_action_begin_msg "Stopping vncserver for user '${USER}' on localhost:${DISPLAY}" su ${USER} -c "/usr/bin/tightvncserver -kill :${DISPLAY}" ;; restart) $0 stop $0 start ;; *) echo "Usage: /etc/init.d/vnc (start|stop|restart)" exit 1 ;;esacexit 0:wq!chmod +x /etc/init.d/vncupdate-rc.d vnc defaults
关闭vncserver
$ vncserver -kill :1# 数字 1 为桌面号,对应客户端的端口为5901,以此类推2,3,4....
0 0
- ubuntu设置tightvncserver自动启动
- ubuntu 14.04 lxde + tightvncserver
- Ubuntu 自动启动程序的设置
- Ubuntu 设置 dhcpd 不要自动启动
- ubuntu中设置synergy自动开机启动
- ubuntu设置gerrit开机自动启动
- ubuntu设置jenkins开机自动启动
- ubuntu开机自动启动程序设置
- Ubuntu Server下设置Tomcat自动启动
- ubuntu下设置Tomcat开启自动启动
- ubuntu设置开机自动启动脚本
- 【Rayeager PX2分享】启动tightvncserver失败解决办法
- 树莓派安装ubuntu,tightvncserver的兼容性问题
- Ubuntu 10.04LTS 设置开机/登录自动启动应用程序
- ubuntu安装vnc server-x11vnc并设置开机自动启动
- ubuntu安装vnc server-x11vnc并设置开机自动启动
- Ubuntu 桌面自动启动
- Ubuntu自动启动程序
- 笔记 interview
- 自定义控件进度条加载
- Linux 网桥配置命令:brctl
- Optimization: Stochastic Gradient Descent
- 基于Docker redis3.2.4 集群 Cluster
- ubuntu设置tightvncserver自动启动
- Spring跨controller数据传输er
- SQL 常见命令
- dubbo配置文件
- centos 6.8 lamp
- A+B(EOF)
- 蓝桥杯-横向打印二叉树
- 消息摘要的编程使用(MD5、SHA、HMAC)
- 简单的控制台五子小游戏棋程序(Java)