Distributions
Ubuntu
Fedora
CentOS
中文资源站
网易开源镜像站
harryxu
V2EX  ›  Linux

有没有办法实现linux用户名别名?

  •  
  •   harryxu ·
    harryxu · Mar 9, 2013 · 4922 views
    This topic created in 4852 days ago, the information mentioned may be changed or developed.
    比如服务器中有个用户叫a,客户端可以通过 ssh a@host 登录
    能不能实现一个别名b, 然后可以通过 ssh b@host 登录,但是和ssh a@host登录的效果一样,实际是同一个用户,也是同一个home目录。

    请教下大家有没有办法实现这样一个功能?
    4 replies    1970-01-01 08:00:00 +08:00
    LazyZhu
        1
    LazyZhu  
       Mar 9, 2013   ❤️ 1
    /etc/passwd 复制 & 改名 ?
    harryxu
        2
    harryxu  
    OP
       Mar 9, 2013
    @LazyZhu 是指把passwd里的某一行直接复制然后修改一下最前面的用户名吗,我去试试哈,谢谢。
    dorentus
        3
    dorentus  
       Mar 9, 2013   ❤️ 1
    loveminds
        4
    loveminds  
       Mar 9, 2013   ❤️ 1
    相同UID、GID就可以
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2792 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 31ms · UTC 13:14 · PVG 21:14 · LAX 06:14 · JFK 09:14
    ♥ Do have faith in what you're doing.