From: Yuriy <law@fm.com.ua> To: ALT Linux Community general discussions <community@lists.altlinux.org> Subject: Re: [Comm] кодировка при запуске через screen и init Date: Wed, 30 Sep 2009 14:12:38 +0300 Message-ID: <4AC33D26.5080303@fm.com.ua> (raw) In-Reply-To: <4AC33BEC.9090801@fm.com.ua> [-- Attachment #1: Type: text/plain, Size: 1305 bytes --] Блин, забыл скрипт запуска приложить... тут кинул в аттаче... Yuriy пишет: > Здравствуйте, > > Запускаю rtorrent через screen при загрузке системы через init.d > скрипт запуска взял тут: > http://libtorrent.rakshasa.no/raw-attachment/wiki/R.../rtorrentInit.sh > (прилагаю в файле rtorrent.init.txt) > > после загрузки оси (в Х-ах) открываю терминал и набираю screen -r > - появляется окно rtorrent, но закачки с русским названием файлов > показываются крякозябликами. > - выхожу из screen rtorrent (Ctrl+D) и запускаю rtorrent сам по себе - > без скрина - та же история, крякозяблики. проверяю локаль: > [albatross@localhost torrents]$ locale > LANG= > LC_CTYPE="POSIX" > LC_NUMERIC="POSIX" > LC_TIME="POSIX" > LC_COLLATE="POSIX" > LC_MONETARY="POSIX" > LC_MESSAGES="POSIX" > LC_PAPER="POSIX" > LC_NAME="POSIX" > LC_ADDRESS="POSIX" > LC_TELEPHONE="POSIX" > LC_MEASUREMENT="POSIX" > LC_IDENTIFICATION="POSIX" > LC_ALL= > [albatross@localhost torrents]$ > > и соответственно rtorrent всё нормально показывает. > Подскажите пожалуйста, где рыть чтоб исравить это дело? > > screen устанавливал через apt. > -- Система - ALTD 5.0 (прототип) - apt настроен на rpm ftp://ftp.linux.kiev.ua/pub/Linux/ALT/5.0/branch/ i586 classic rpm ftp://ftp.linux.kiev.ua/pub/Linux/ALT/5.0/branch/ noarch classic [-- Attachment #2: rtorrent.init.txt --] [-- Type: text/plain, Size: 2279 bytes --] [root@localhost ~]# egrep -v \#\|^$ /etc/init.d/rtorrent user="albatross" HOME="/home/albatross" config="`su -c 'echo $HOME' $user`/.rtorrent.rc" echo $config options="" base="`su -c 'echo $HOME' $user`" srnname="rtorrent" logfile="/var/log/rtorrentInit.log" PATH=/usr/bin:/usr/local/bin:/usr/local/sbin:/sbin:/bin:/usr/sbin DESC="rtorrent" NAME=rtorrent DAEMON=$NAME SCRIPTNAME=/etc/init.d/$NAME checkcnfg() { exists=0 for i in `echo "$PATH" | tr ':' '\n'` ; do if [ -f $i/$NAME ] ; then exists=1 break fi done if [ $exists -eq 0 ] ; then echo "cannot find rtorrent binary in PATH $PATH" | tee -a "$logfile" >&2 exit 3 fi if ! [ -r "${config}" ] ; then echo "cannot find readable config ${config}. check that it is there and permissions are appropriate" | tee -a "$logfile" >&2 exit 3 fi session=`getsession "$config"` if ! [ -d "${session}" ] ; then echo "cannot find readable session directory ${session} from config ${co nfig}. check permissions" | tee -a "$logfile" >&2 exit 3 fi } d_start() { [ -d "${base}" ] && cd "${base}" stty stop undef && stty start undef su -c "screen -ls | grep -sq "\.${srnname}[[:space:]]" " ${user} || su -c "scr een -dm -S ${srnname} 2>&1 1>/dev/null" ${user} | tee -a "$logfile" >&2 su -c "screen -S "${srnname}" -X screen rtorrent ${options} 2>&1 1>/dev/null" ${user} | tee -a "$logfile" >&2 } d_stop() { session=`getsession "$config"` if ! [ -s ${session}/rtorrent.lock ] ; then return fi pid=`cat ${session}/rtorrent.lock | awk -F: '{print($2)}' | sed "s/[^0-9]//g "` kill -s INT ${pid} fi } getsession() { session=`cat "$1" | grep "^[[:space:]]*session[[:space:]]*=" | sed "s/^[[:sp ace:]]*session[[:space:]]*=[[:space:]]*//" ` echo $session } checkcnfg case "$1" in start) echo -n "Starting $DESC: $NAME" d_start echo "." ;; stop) echo -n "Stopping $DESC: $NAME" d_stop echo "." ;; restart|force-reload) echo -n "Restarting $DESC: $NAME" d_stop sleep 1 d_start echo "." ;; *) echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload}" >&2 exit 1 ;; esac exit 0 [root@localhost ~]#
next prev parent reply other threads:[~2009-09-30 11:12 UTC|newest] Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top 2009-09-30 11:07 Yuriy 2009-09-30 11:12 ` Yuriy [this message] 2009-10-01 3:07 ` Gleb Kulikov 2009-10-01 9:10 ` Yuriy 2009-10-02 10:39 ` Yuriy
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=4AC33D26.5080303@fm.com.ua \ --to=law@fm.com.ua \ --cc=community@lists.altlinux.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
ALT Linux Community general discussions This inbox may be cloned and mirrored by anyone: git clone --mirror http://lore.altlinux.org/community/0 community/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 community community/ http://lore.altlinux.org/community \ mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com public-inbox-index community Example config snippet for mirrors. Newsgroup available over NNTP: nntp://lore.altlinux.org/org.altlinux.lists.community AGPL code for this site: git clone https://public-inbox.org/public-inbox.git