Strona 1 z 2
Debian Squeeze i istniejący nieistniejący plik
: 26 sierpnia 2010, 03:51
autor: KacperOo
Mam bardzo dziwny problem ze swoim serwerem na Debianie Squeeze. Mianowicie plik istnieje, jednak nie mogę mu nadać prawa do jego wykonywania +x (normalnie kolor w ls zmieniał się na zielony), a gdy chcę go uruchomić dowiaduję się, że nie ma takiego pliku.
Poniżej załączam logi:
Kod: Zaznacz cały
ks310411:~/irpvc# ls
announov filterscripts npcmodes samp-npc server_log.txt
audio.ini gamemodes plugins scriptfiles
audiopacks mysql_log.txt samp03svr-ov server.cfg
ks310411:~/irpvc# chmod +x samp03svr-ov
ks310411:~/irpvc# ./samp03svr-ov
-bash: ./samp03svr-ov: Nie ma takiego pliku ani katalogu
ks310411:~/irpvc#
Z góry dziękuję za pomoc,
Kacper
: 26 sierpnia 2010, 10:16
autor: fnmirk
W jakim katalogu masz umieszczony ten plik? Próbowałeś podać do niego pełną ścieżkę dostępu?
: 26 sierpnia 2010, 12:11
autor: KacperOo
/home/ownede/irpvc/
Kod: Zaznacz cały
ks310411:~# exec /home/ownede/irpvc/samp03svr-ov
-bash: /home/ownede/irpvc/samp03svr-ov: Nie ma takiego pliku ani katalogu
-bash: /home/ownede/irpvc/samp03svr-ov: Sukces
ks310411:~# .//home/ownede/irpvc/samp03svr-ov
-bash: .//home/ownede/irpvc/samp03svr-ov: Nie ma takiego pliku ani katalogu
Nie mam pojęcia co to może być.
: 26 sierpnia 2010, 13:58
autor: lun
Daj wynik
z tego katalogu.
Przejrzyj logi może tam coś będzie widać.
: 26 sierpnia 2010, 14:01
autor: KacperOo
lun pisze:Daj wynik
z tego katalogu.
Przejrzyj logi może tam coś będzie widać.
Kod: Zaznacz cały
ownede@ks310411:~/irpvc$ ls -l
razem 7140
-rwxr-xr-x 1 ownede ownede 11292 05-08 20:42 announov
-rw-r--r-- 1 ownede ownede 807 2010-01-23 audio.ini
drwxr-xr-x 4 ownede ownede 4096 08-06 11:59 audiopacks
drwxr-xr-x 2 ownede ownede 4096 08-06 11:59 filterscripts
drwxr-xr-x 2 ownede ownede 4096 08-06 12:00 gamemodes
-rw-r--r-- 1 ownede ownede 5011178 06-22 13:06 mysql_log.txt
drwxr-xr-x 3 ownede ownede 4096 08-06 12:01 npcmodes
drwxr-xr-x 2 ownede ownede 4096 08-06 12:01 plugins
-rwxrwxrwx 1 ownede ownede 1016308 05-08 20:42 samp03svr-ov
-rw-r--r-- 1 ownede ownede 604740 05-08 20:42 samp-npc
drwxr-xr-x 2 ownede ownede 4096 08-06 12:02 scriptfiles
-rw-r--r-- 1 ownede ownede 411 05-31 21:43 server.cfg
-rw-r--r-- 1 ownede ownede 598876 06-22 13:06 server_log.txt
(chmody są, ale nadal nie mogę odpalić)
: 26 sierpnia 2010, 14:35
autor: lun
Szczerze mówiąc to nic sensownego nie przychodzi mi do głowy.
Spróbuj zrobić tak
Kod: Zaznacz cały
touch samp03svr-ov.2
cat samp03svr-ov > samp03svr-ov.2
chmod +x samp03svr-ov.2
./samp03svr-ov.2
Jeśli nazwa tego pliku nie jest z jakiegoś powodu istotna, to zobacz co się dzieje jak stworzysz nowy plik i skopiujesz do niego zawartość oryginału.
: 26 sierpnia 2010, 14:39
autor: KacperOo
Kod: Zaznacz cały
ownede@ks310411:~/irpvc$ touch samp03svr-ov.2
ownede@ks310411:~/irpvc$ cat samp03svr-ov > samp03svr-ov.2
ownede@ks310411:~/irpvc$ chmod +x samp03svr-ov.2
ownede@ks310411:~/irpvc$ ./samp03svr-ov.2
-bash: ./samp03svr-ov.2: Nie ma takiego pliku ani katalogu
Jak zabawa w kotka i myszkę.
: 26 sierpnia 2010, 15:03
autor: lun
To może jeszcze pokaż
Kod: Zaznacz cały
cat /home/ownede/.bash_profile
cat /home/ownede/.bashrc
Jeśli tam nic nie będzie, to wyczerpią mi się pomysły.
: 26 sierpnia 2010, 15:10
autor: tremor
Coś z nagłówkiem pliku jest nie tak. Spróbuj go odpalić:
: 26 sierpnia 2010, 20:43
autor: KacperOo
tremor pisze:Coś z nagłówkiem pliku jest nie tak. Spróbuj go odpalić:
Kod: Zaznacz cały
ownede@ks310411:~/irpvc$ bash samp03svr-ov
samp03svr-ov: samp03svr-ov: cannot execute binary file
ownede@ks310411:~/irpvc$ bash samp03svr-ov.2
ownede@ks310411:~/irpvc$
Kod: Zaznacz cały
ownede@ks310411:~$ cat /home/ownede/.bash_profile
cat: /home/ownede/.bash_profile: Nie ma takiego pliku ani katalogu
ownede@ks310411:~$ cat /home/ownede/.bashrc
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
[ -z "$PS1" ] && return
# don't put duplicate lines in the history. See bash(1) for more options
# don't overwrite GNU Midnight Commander's setting of `ignorespace'.
export HISTCONTROL=$HISTCONTROL${HISTCONTROL+,}ignoredups
# ... or force ignoredups and ignorespace
export HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# make less more friendly for non-text input files, see lesspipe(1)
#[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm-color) color_prompt=yes;;
esac
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
#force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
#if [ -f ~/.bash_aliases ]; then
# . ~/.bash_aliases
#fi
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
eval "`dircolors -b`"
alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
#alias grep='grep --color=auto'
#alias fgrep='fgrep --color=auto'
#alias egrep='egrep --color=auto'
fi
# some more ls aliases
#alias ll='ls -l'
#alias la='ls -A'
#alias l='ls -CF'
# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if [ -f /etc/bash_completion ]; then
. /etc/bash_completion
fi
ownede@ks310411:~$
Dodane:
Kod: Zaznacz cały
ownede@ks310411:~$ cat /home/ownede/.bash_profile
cat: /home/ownede/.bash_profile: Nie ma takiego pliku ani katalogu
oraz
Kod: Zaznacz cały
ownede@ks310411:~$ cat /home/ownede/.bashrc
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
[ -z "$PS1" ] && return
# don't put duplicate lines in the history. See bash(1) for more options
# don't overwrite GNU Midnight Commander's setting of `ignorespace'.
export HISTCONTROL=$HISTCONTROL${HISTCONTROL+,}ignoredups
# ... or force ignoredups and ignorespace
export HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# make less more friendly for non-text input files, see lesspipe(1)
#[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm-color) color_prompt=yes;;
esac
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
#force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
#if [ -f ~/.bash_aliases ]; then
# . ~/.bash_aliases
#fi
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
eval "`dircolors -b`"
alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
#alias grep='grep --color=auto'
#alias fgrep='fgrep --color=auto'
#alias egrep='egrep --color=auto'
fi
# some more ls aliases
#alias ll='ls -l'
#alias la='ls -A'
#alias l='ls -CF'
# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if [ -f /etc/bash_completion ]; then
. /etc/bash_completion
fi
ownede@ks310411:~$