z/OS Tools & Language

Expand all | Collapse all

MC: Problem starting Midnight Commander

Tatiana Balaburkina08-04-2017 08:03

  • 1.  MC: Problem starting Midnight Commander

    Posted 08-03-2017 03:19

    I’ve installed mc on USS from your package, but get this error when I try to run it:

    Warning: file /usr/local/mc/share/mc/extfs/extfs.ini not found
    Warning: file /usr/local/mc/share/mc/extfs/sfs.ini not found

    Cannot set pty terminal modes: EDC5139I Operation not permitted. (139)
    read (subshell_pty…): EDC5137I Inappropriate I/O control operation. (137)

    Do you have an idea about what is going wrong?



  • 2.  RE: MC: Problem starting Midnight Commander

    Posted 08-03-2017 04:26

    Hi,

    Could you try to add this line into a config file (e.g., ~/.profile, ~/.bashrc):

    export TERMINFO=/path_to_your_directory/share/mc



  • 3.  RE: MC: Problem starting Midnight Commander

    Posted 08-03-2017 04:46

    Hi,

    Thanks for a fast reply.

    Unfortunately it didn’t change anything.



  • 4.  RE: MC: Problem starting Midnight Commander

    Posted 08-03-2017 04:50

    Which shell do you use? sh or bash (version)?
    Also try to add in config:

    export TERM=xterm



  • 5.  RE: MC: Problem starting Midnight Commander

    Posted 08-04-2017 07:38

    I’m using bash 4.3. TERM is set to xterm.



  • 6.  RE: MC: Problem starting Midnight Commander

    Posted 08-04-2017 08:01

    Where did you set TERM and TERMINFO? Could you share content of this configuration file?



  • 7.  RE: MC: Problem starting Midnight Commander

    Posted 08-04-2017 08:03

    *** Rocket internal tracking reference: USSP-839 ***



  • 8.  RE: MC: Problem starting Midnight Commander

    Posted 08-04-2017 08:05

    Hi Tatyana,

    This is the content of my .bashrc file.

    export PS1=’\s-\v’:‘ÅPWD’:’>'
    Æ
    export CICS_HOME="/service/c520/u"
    export JAVA_HOME="/usr/lpp/java/J7.1_64/bin"
    Æ
    export GIT_SHELL=ÅHOME"/bin/bash"
    export GIT_EXEC_PATH=ÅHOME"/libexec/git-core"
    export GIT_TEMPLATE_DIR=ÅHOME"/share/git-core/templates"
    Æ Æ common the environment variables
    export PATH="/bin:“ÅHOME”/bin"
    export PATH=ÅPATH":/usr/lpp/java/J7.1_64/bin:.“
    export MANPATH=”/usr/man/%L:“ÅHOME”/man/%L"
    export LIBPATH="/lib:/usr/lib:“ÅHOME”/lib:.“
    export PERL5LIB=ÅHOME”/lib/perl5"
    Æ Æ ASCII support the environment variables
    export _BPXK_AUTOCVT=ON
    export _CEE_RUNOPTS=“FILETAG(AUTOCVT,AUTOTAG) POSIX(ON)“
    export _TAG_REDIR_ERR=txt
    export _TAG_REDIR_IN=txt
    export _TAG_REDIR_OUT=txt
    Æ
    export BASH_PREFIX=ÅHOME”/bin"
    export PERL_PREFIX=ÅHOME”/bin"
    Æ
    INSTALL=ÅHOME"/python"
    export RELEASE_NAME=python-2017-04-12
    Æ Æ export RELEASE_TYPE=py27 # or py36 or both, to match the download
    export RELEASE_TYPE=py36
    export RELEASE_DIR=ÅINSTALL/ÅRELEASE_NAME-ÅRELEASE_TYPE
    Æ Æ export PYTHON_ENV=python27 # pr python36 or both, to match your desired environment
    export PYTHON_ENV=python36
    export PKGS_BASE=ÅRELEASE_DIR/pkgs
    Æ
    export PYTHON_HOME=ÅRELEASE_DIR/ÅPYTHON_ENV
    export PATH=ÅPATH:ÅPYTHON_HOME/bin
    export LIBPATH=ÅLIBPATH:ÅPYTHON_HOME/lib
    export FFI_LIB=ÅPYTHON_HOME/lib/ffi
    export TERMINFO=/u/g22392/share/mc
    Æ export TERMINFO=ÅPYTHON_HOME/share/terminfo
    export PKG_CONFIG_PATH=ÅPYTHON_HOME/lib/pkgconfig:ÅPYTHON_HOME/share/pkgconfig



  • 9.  RE: MC: Problem starting Midnight Commander

    Posted 08-04-2017 08:22

    Something bad happened in the cut’n’paste. Can you please upload the file as an attachment?



  • 10.  RE: MC: Problem starting Midnight Commander

    Posted 08-04-2017 08:40

    I’m not allowed to upload that kind of file :slight_smile:

    If you think of the Æ (#) and Å ($) then it’s due to the Danish codepage.



  • 11.  RE: MC: Problem starting Midnight Commander

    Posted 08-04-2017 09:02

    You can rename it to end in “.txt”.



  • 12.  RE: MC: Problem starting Midnight Commander

    Posted 08-04-2017 09:05

    Never mind - here it is.

     export PS1=’\s-\v’:‘$PWD’:’>'
     #
     export CICS_HOME="/service/c520/u"
     export JAVA_HOME="/usr/lpp/java/J7.1_64/bin"
     #
     export GIT_SHELL=$HOME"/bin/bash"
     export GIT_EXEC_PATH=$HOME"/libexec/git-core"
     export GIT_TEMPLATE_DIR=$HOME"/share/git-core/templates"
     # # common the environment variables
     export PATH="/bin:“$HOME”/bin"
     export PATH=$PATH":/usr/lpp/java/J7.1_64/bin:.“
     export MANPATH=”/usr/man/%L:“$HOME”/man/%L"
     export LIBPATH="/lib:/usr/lib:“$HOME”/lib:.“
     export PERL5LIB=$HOME”/lib/perl5"
     # # ASCII support the environment variables
     export _BPXK_AUTOCVT=ON
     export _CEE_RUNOPTS=“FILETAG(AUTOCVT,AUTOTAG) POSIX(ON)“
     export _TAG_REDIR_ERR=txt
     export _TAG_REDIR_IN=txt
     export _TAG_REDIR_OUT=txt
     #
     export BASH_PREFIX=$HOME”/bin"
     export PERL_PREFIX=$HOME”/bin"
     #
     INSTALL=$HOME"/python"
     export RELEASE_NAME=python-2017-04-12
     # # export RELEASE_TYPE=py27 # or py36 or both, to match the download
     export RELEASE_TYPE=py36
     export RELEASE_DIR=$INSTALL/$RELEASE_NAME-$RELEASE_TYPE
     # # export PYTHON_ENV=python27 # pr python36 or both, to match your desired environment
     export PYTHON_ENV=python36
     export PKGS_BASE=$RELEASE_DIR/pkgs
     #
     export PYTHON_HOME=$RELEASE_DIR/$PYTHON_ENV
     export PATH=$PATH:$PYTHON_HOME/bin
     export LIBPATH=$LIBPATH:$PYTHON_HOME/lib
     export FFI_LIB=$PYTHON_HOME/lib/ffi
     export TERMINFO=/u/g22392/share/mc
     # export TERMINFO=$PYTHON_HOME/share/terminfo
     export PKG_CONFIG_PATH=$PYTHON_HOME/lib/pkgconfig:$PYTHON_HOME/share/pkgconfig


  • 13.  RE: MC: Problem starting Midnight Commander

    Posted 08-04-2017 09:10

    But it runs fine on USS. It’s only MC that doesn’t work.
    The codepage is changed when I save it in USS via Topaz Workbench.



  • 14.  RE: MC: Problem starting Midnight Commander

    Posted 08-08-2017 08:07

    Not sure I explained my self that well.
    I still can’t use Midnight Commander, still get the same error.
    My .bashrc works for other stuff.



  • 15.  RE: MC: Problem starting Midnight Commander

    Posted 08-08-2017 08:12

    Regarding the warnings you should set
    export MC_DATADIR=/path_to_your_directory/share/mc
    (path_to_your_directory means the directory where your mc is installed).

    Regarding the permissions: could you please show a listing of your /dev/ directory?



  • 16.  RE: MC: Problem starting Midnight Commander

    Posted 08-08-2017 08:48

    This is the content of /dev:

    bash-4.3:/dev:>dir
    total 32
    drwxrwxrwx 2 DS2TDIST SYS1 8192 Aug 3 09:24 .
    drwxr-xr-x 11 G36320 D8781 8192 Oct 10 2013 …
    c-w–w--w- 1 DS2TDIST SYS1 9, 0 Aug 2 21:10 console
    crw-rw-rw- 1 DS2TDIST SYS1 5, 0 Aug 2 21:14 fd0
    crw-rw-rw- 1 DS2TDIST SYS1 5, 1 Aug 2 21:14 fd1
    crw-rw-rw- 1 DS2TDIST SYS1 5, 2 Aug 3 09:24 fd2
    crw-rw-rw- 1 DS2TDIST SYS1 5, 4 Aug 2 21:13 fd4
    crw-rw-rw- 1 DS2TDIST SYS1 5, 5 Aug 2 21:13 fd5
    srw-rw-rw- 1 DS2TDIST SYS1 0 Aug 2 21:13 log
    crwxrwxrwx 1 DS2TDIST SYS1 4, 0 Aug 2 21:10 null
    c-w------- 1 DS2TDIST SYS1 9, 1 Aug 2 21:10 operlog
    crw-rw-rw- 1 DS2TDIST SYS1 1, 0 Aug 8 14:42 ptyp0000
    crw-rw-rw- 1 DS2TDIST SYS1 1, 1 Aug 8 14:42 ptyp0001
    crw-rw-rw- 1 DS2TDIST SYS1 4, 2 Aug 2 21:10 random
    crw-rw-rw- 1 DS2TDIST SYS1 3, 0 Aug 2 21:10 tty
    crw–w---- 1 G22392 DFSGRP 2, 0 Aug 8 14:42 ttyp0000
    crw-rw-rw- 1 DS2TDIST SYS1 2, 1 Aug 8 13:23 ttyp0001
    crw-rw-rw- 1 DS2TDIST SYS1 4, 2 Aug 2 21:10 urandom
    crw-rw-rw- 1 DS2TDIST SYS1 4, 1 Aug 2 21:10 zero
    bash-4.3:/dev:>

    After setting the MC_DATADIR I get these error messages:
    Cannot set pty terminal modes: EDC5139I Operation not permitted. (139)
    read (subshell_pty…): EDC5137I Inappropriate I/O control operation. (137)



  • 17.  RE: MC: Problem starting Midnight Commander

    Posted 08-08-2017 09:41

    Not sure about the listing of /dev. In my installation /dev/ttyp0000 has group TTY. Don’t know if that is required.

    Could you check that your system has a group TTY and if yes, could you please assign
    chgrp TTY /dev/ttyp0000

    However, not sure if this is the cause of any evil.



  • 18.  RE: MC: Problem starting Midnight Commander

    Posted 08-08-2017 10:29

    I forgot to say if your system does not have a group TTY (which of course must have an omvs segment) then this is a problem for sure.



  • 19.  RE: MC: Problem starting Midnight Commander

    Posted 08-08-2017 10:17

    Did you use to start MC this way:

    mc -u



  • 20.  RE: MC: Problem starting Midnight Commander

    Posted 08-10-2017 02:43

    Thanks Tatyana,

    The mc -u did the trick. Works now.
    So these two solutions worked for me:

    export MC_DATADIR=/path_to_your_directory/share/mc
    mc -u

    Thanks a lot for your help.

    BR
    Torben



  • 21.  RE: MC: Problem starting Midnight Commander

    Posted 08-08-2017 09:34

    was targeted against:

    Warning: file /usr/local/mc/share/mc/extfs/extfs.ini not found
    Warning: file /usr/local/mc/share/mc/extfs/sfs.ini not found