chmod - 管理者以外のユーザーに権限を実行しますか?

chmod - 管理者以外のユーザーに権限を実行しますか?

私はかつてchmodディレクトリ内のすべてを実行可能にしました。ただし、そのディレクトリにあるプログラムの1つを一般ユーザー(私)として実行しようとすると、「コマンドが見つかりません」というメッセージが表示されます。を実行するとsuプログラムが実行されます。私は何を見逃していますか?私はFedora 22を使用しています。これは完全なbashセッションです。 (また、私のGitのインストールが不完全であることを示していますが、それは重要ではないと思います.)

bash: home/brian/git-completion.bash: No such file or directory
bash: /home/brian/git-prompt.sh: No such file or directory
bash: __git_ps1: command not found...
brian ~ $ ipython
bash: ipython: command not found...
Similar command is: 'python'
bash: __git_ps1: command not found...
brian ~ $ su
Password: 
bash: home/brian/git-completion.bash: No such file or directory
bash: /root/git-prompt.sh: No such file or directory
bash: __git_ps1: command not found...
root brian $ ipython
Python 2.7.10 |Anaconda 2.3.0 (64-bit)| (default, May 28 2015, 17:02:03) 
Type "copyright", "credits" or "license" for more information.

IPython 3.2.0 -- An enhanced Interactive Python.
Anaconda is brought to you by Continuum Analytics.
Please check out: http://continuum.io/thanks and https://anaconda.org
?         -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help      -> Python's own help system.
object?   -> Details about 'object', use 'object??' for extra details.

In [1]: 

また、私の.bashrcの完全なリストは次のとおりです。

sudo# .bashrc

# User specific aliases and functions

alias rm='rm -i'
alias cp='cp -i'
alias mv='mv -i'

# Source global definitions
if [ -f /etc/bashrc ]; then
    . /etc/bashrc
fi

# Enable tab completion
source home/brian/git-completion.bash

# colors!
green="\[\033[0;32m\]"
blue="\[\033[0;34m\]"
purple="\[\033[0;35m\]"
reset="\[\033[0m\]"

# Change command prompt
source ~/git-prompt.sh
export GIT_PS1_SHOWDIRTYSTATE=1
# '\u' adds the name of the current user to the prompt
# '\$(__git_ps1)' adds git-related stuff
# '\W' adds the name of the current directory
export PS1="$purple\u$green\$(__git_ps1)$blue \W $ $reset"

# added by Anaconda 2.3.0 installer
export PATH="/root/anaconda/bin:$PATH"

ベストアンサー1

これは権限に関連していないようです。 「コマンドが見つかりません」の代わりに「権限が拒否されました」と表示されます。

.何が起こるかは、あなたがあなたの$PATH根を持っているように見えるということです。クレイジー)、しかし、あなたのアカウントには適用されません。

追加してください。安全ですか?私の道は?どうですか?

答え:いいえ。 tar.gz Extractcdディレクトリを実行し、Just own your コンピュータを実行します。lsls/bin/ls~/.bashrcsu

現在のディレクトリで何かを実行するには、次を実行します。./cmd

おすすめ記事