[9fans] auth/changeuser from drawterm - Plan9

This is a discussion on [9fans] auth/changeuser from drawterm - Plan9 ; Dear 9fans, in order to be able to do administrative tasks through drawterm I habe added the following to my cpurc: srvfs nimda / Then I expected to mount /mnt/keys and friends in a drawterm as bootes like this: mount ...

+ Reply to Thread
Results 1 to 4 of 4

Thread: [9fans] auth/changeuser from drawterm

  1. [9fans] auth/changeuser from drawterm

    Dear 9fans,

    in order to be able to do administrative tasks through drawterm I
    habe added the following to my cpurc:

    srvfs nimda /

    Then I expected to mount /mnt/keys and friends in a drawterm as
    bootes like this:

    mount -bc /srv/nimda /

    A ls /mnt/keys now shows the existing loaded keys. A auth/changeuser
    joe now sits there indefinitely and does nothing it seems (ps shows
    Pread).

    Mr. Diaz uses a mount -c / bind -b combination of the srvfs mntpoint
    for serviente but this approach does have the same results for me.

    Question time:

    1. is mount -bc /srv/foo / the same as mount -c /srv/foo /n/root
    bind -b /n/root /?
    2. Why does auth/changeuser have this behaviour?
    3. How can I find out what's going on?

    Thanks for your attention!

    Kind regards,

    Christian

    --
    You may use my gpg key for replies:
    pub 1024D/47F79788 2005/02/02 Christian Kellermann (C-Keen)

    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v1.4.7 (OpenBSD)

    iD8DBQFH4i4iXYob3Uf3l4gRAlAxAKDG03BdIHuTyb1J2m7V68 +CITTCyACgli8B
    RyrG8TxhGsG3BwolICeC9LA=
    =n5Ju
    -----END PGP SIGNATURE-----


  2. Re: [9fans] auth/changeuser from drawterm

    To give you some more information:

    It seems that auth/changeuser hangs in reading from /dev/cons:
    cpu% ps | grep changeuser
    bootes 2276 0:00 0:00 72K Pread changeuser
    cpu% acid 2276
    /proc/2276/text:386 plan 9 executable
    /sys/lib/acid/port
    /sys/lib/acid/386
    acid: stk()
    pread()+0x7 /sys/src/libc/9syscall/pread.s:5
    read(fd=0x4,buf=0xdfffef09,n=0x1)+0x2f /sys/src/libc/9sys/read.c:7
    readln(prompt=0xe31c,raw=0x1,line=0xdfffef09,len=0 x20)+0xcf /sys/src/cmd/auth/lib/readln.c:84
    getpass(pass=0xdfffef09,confirm=0x1,key=0xdfffef49 ,check=0x1)+0x39 /sys/src/cmd/auth/lib/readln.c:18
    main(argv=0xdfffefa8,argc=0x1)+0x1bf /sys/src/cmd/auth/changeuser.c:65
    _main+0x31 /sys/src/libc/386/main9.s:16
    acid:

    Fd 4 is /dev/cons in this case...

    This happens when doing any of the following:

    drawterm to the machine as some user, then cpu'ing to localhost, then mounting the served root and calling auth/changeuser.

    drawterm to the machine as bootes, omitting the cpu call and proceed as above

    This all happens with auth/debug as well, which has been known to work withdrawterm to my knowledge.

    Kind regards,

    Christian

    --
    You may use my gpg key for replies:
    pub 1024D/47F79788 2005/02/02 Christian Kellermann (C-Keen)

    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v1.4.7 (OpenBSD)

    iD8DBQFH4kSBXYob3Uf3l4gRAvzmAKCiePIOQr3NRWOtfDbb1e pSe8gRVACfSJT1
    QT+/KXcYEAHLgvhvJur8/wc=
    =IXAb
    -----END PGP SIGNATURE-----


  3. Re: [9fans] auth/changeuser from drawterm

    gdiaz found my error: of course if I buĂ*nd -b /n/root / /dev/cons
    of the server is used and not one of the stacked from the drawterms...
    just binding the mnt dir resolves this issue.

    I officially owe gdiaz some beer.

    Sorry for the noise!

    Christian

    --
    You may use my gpg key for replies:
    pub 1024D/47F79788 2005/02/02 Christian Kellermann (C-Keen)

    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v1.4.7 (OpenBSD)

    iD8DBQFH4kZ5XYob3Uf3l4gRArwqAJ0VFeMGZ99h4N+RN77I06 96WkOV6QCeOdse
    Og+ipf8NLr5fEgJlW/5FWU4=
    =F8b4
    -----END PGP SIGNATURE-----


  4. Re: [9fans] auth/changeuser from drawterm

    > Dear 9fans,
    >
    > in order to be able to do administrative tasks through drawterm I
    > habe added the following to my cpurc:

    [...]

    it's really worth setting up a serial console and console server to avoid
    these issues. at home i use cec. there's a patch here
    /n/sources/patch/saved
    it's a little quirky, but if you don't have a spare serial port & null modem
    it beats nothing.

    - erik


+ Reply to Thread