【xrdp配置文件】

这里写自定义目录标题

/etc/xrdp/sesman.ini

;; See man 5 sesman.ini for details

  • 这一行提示用户可以查阅手册页来获取更多关于sesman.ini配置文件的细节信息。

Globals

ListenAddress=127.0.0.1

ListenPort=3350

EnableUserWindowManager=true

; Give in relative path to user's home directory

UserWindowManager=startwm.sh

; Give in full path or relative path to /etc/xrdp

DefaultWindowManager=startwm.sh

; Give in full path or relative path to /etc/xrdp

ReconnectScript=reconnectwm.sh

  • [Globals]部分定义了全局设置。
  • ListenAddress指定了监听地址为本地环回地址,这意味着它只接受来自同一主机的连接请求。
  • ListenPort设定了监听端口为3350,这是xrdp会话管理器默认使用的端口。
  • EnableUserWindowManager选项允许启用用户的窗口管理器脚本。
  • UserWindowManagerDefaultWindowManager都指向启动窗口管理器的脚本startwm.sh,前者是相对于用户主目录的路径,后者是相对于/etc/xrdp的路径。
  • ReconnectScript定义了一个重新连接时执行的脚本。

Security

AllowRootLogin=true

MaxLoginRetry=10

TerminalServerUsers=tsusers

TerminalServerAdmins=tsadmins

; When AlwaysGroupCheck=false access will be permitted

; if the group TerminalServerUsers is not defined.

AlwaysGroupCheck=false

; When RestrictOutboundClipboard=true clipboard from the

; server is not pushed to the client.

RestrictOutboundClipboard=false

  • [Security]部分包含了与安全相关的配置。
  • AllowRootLogin设置为true意味着允许以root身份登录,这对于某些环境来说可能是不安全的选择。
  • MaxLoginRetry限制了登录失败的最大尝试次数为10次。
  • TerminalServerUsersTerminalServerAdmins定义了终端服务器用户组和管理员组的名字。
  • AlwaysGroupCheck当设置为false时,即使没有定义TerminalServerUsers组也允许访问。
  • RestrictOutboundClipboard控制是否限制服务器剪贴板内容传输给客户端。

Sessions

;; X11DisplayOffset - x11 display number offset

; Type: integer

; Default: 10

X11DisplayOffset=10
;; MaxSessions - maximum number of connections to an xrdp server

; Type: integer

; Default: 0

MaxSessions=50
;; KillDisconnected - kill disconnected sessions

; Type: boolean

; Default: false

; if 1, true, or yes, kill session after 60 seconds

KillDisconnected=false
;; DisconnectedTimeLimit - when to kill idle sessions

; Type: integer

; Default: 0

; if not zero, the seconds before a disconnected session is killed

; min 60 seconds

DisconnectedTimeLimit=0
;; IdleTimeLimit (specify in second) - wait before disconnect idle sessions

; Type: integer

; Default: 0

; Set to 0 to disable idle disconnection.

IdleTimeLimit=0
;; Policy - session allocation policy

; Type: enum [ "Default" | "UBD" | "UBI" | "UBC" | "UBDI" | "UBDC" ]

; Default: Xrdp:<User,BitPerPixel> and Xvnc:<User,BitPerPixel,DisplaySize>

; "UBD" session per <User,BitPerPixel,DisplaySize>

; "UBI" session per <User,BitPerPixel,IPAddr>

; "UBC" session per <User,BitPerPixel,Connection>

; "UBDI" session per <User,BitPerPixel,DisplaySize,IPAddr>

; "UBDC" session per <User,BitPerPixel,DisplaySize,Connection>

Policy=Default

  • [Sessions]部分配置了会话管理规则。
  • X11DisplayOffset设置了X11显示编号的偏移量。
  • MaxSessions指定了最大并发连接数为50个。
  • KillDisconnected如果设置为true,则会在断开连接后60秒内终止会话。
  • DisconnectedTimeLimit定义了在断开连接多久之后结束会话的时间限制,这里设置为0表示禁用此功能。
  • IdleTimeLimit同样用于设定空闲会话的超时时间,设为0则不会因为空闲而断开会话。
  • Policy确定了会话分配策略,默认值适用于大多数情况。

Logging

LogFile=xrdp-sesman.log

LogLevel=DEBUG

EnableSyslog=1

SyslogLevel=DEBUG

  • [Logging]部分配置日志记录选项。
  • LogFile指定了日志文件的位置。
  • LogLevel和SyslogLevel都设为了DEBUG级别,意味着记录非常详细的调试信息。
  • EnableSyslog启用或禁用系统日志记录功能。
相关推荐
眠修16 分钟前
Kuberrnetes 服务发布
linux·运维·服务器
即将头秃的程序媛3 小时前
centos 7.9安装tomcat,并实现开机自启
linux·运维·centos
fangeqin3 小时前
ubuntu源码安装python3.13遇到Could not build the ssl module!解决方法
linux·python·ubuntu·openssl
爱奥尼欧5 小时前
【Linux 系统】基础IO——Linux中对文件的理解
linux·服务器·microsoft
超喜欢下雨天5 小时前
服务器安装 ros2时遇到底层库依赖冲突的问题
linux·运维·服务器·ros2
tan77º6 小时前
【Linux网络编程】网络基础
linux·服务器·网络
笑衬人心。6 小时前
Ubuntu 22.04 + MySQL 8 无密码登录问题与 root 密码重置指南
linux·mysql·ubuntu
chanalbert8 小时前
CentOS系统新手指导手册
linux·运维·centos
星宸追风8 小时前
Ubuntu更换Home目录所在硬盘的过程
linux·运维·ubuntu
热爱生活的猴子9 小时前
Poetry 在 Linux 和 Windows 系统中的安装步骤
linux·运维·windows