j***y 发帖数: 87 | 1 cd your_home_directory
mv chmod a_temp_name
cp /bin/ls chmod
cat a_temp_name >chmod |
|
a******1 发帖数: 47 | 2 你是想用 chmod -R 700 * 吧 (R要大写表示recursively)
你用chmod -r 700 *,相当于给文件名为700的文件(其实这个文件不存在,执行的
时候应该有警告信息出现过)和 所有文件(*)去掉read权限(-r),owner的read
权限也给你去掉了,就用不了ls了,因为linux下所有的directory都是以文件的形式存
放的,你没有看的权限,就用不了ls命令了。du -h也一样。
ls不能用的话,用getfacl命令看看你这个文件夹和 . 文件是不是被你整成没有r权限
了, |
|
D******n 发帖数: 2836 | 3 【 以下文字转载自 Linux 讨论区 】
发信人: DaShagen (Unbearable lightness), 信区: Linux
标 题: strange behavior about chmod 777 -R
发信站: BBS 未名空间站 (Mon Sep 26 14:47:54 2011, 美东)
I asked my colleague to change all files/folders under a folder to
accessible by all.
I asked her to do chmod 777 -R AAAA/
she said she did,
but i found one folder AAAA/bbb/ccc still not changed, while all files under
that folder has been changed to "777' mode. Why is that?
because she lied ?
Thanks. |
|
r*u 发帖数: 63 | 4 for people in our group I usually use
chmod 755 files
for executables
or chmod 744 files
for read-onlys. |
|
D******n 发帖数: 2836 | 5 I asked my colleague to change all files/folders under a folder to
accessible by all.
I asked her to do chmod 777 -R AAAA/
she said she did,
but i found one folder AAAA/bbb/ccc still not changed, while all files under
that folder has been changed to "777' mode. Why is that?
because she lied ?
Thanks. |
|
D******n 发帖数: 2836 | 6 ya, i will never know.
i pointed to her the folder, and she changed it. it worked.
so i guess she lied, she didnt do chmod 777 -R |
|
D******n 发帖数: 2836 | 7 omg, it happened again. this time i went over to my colleague's desk to type
the command. and the folder's permission is not changed!
here is the situations.
I typed chmod -Rf 777 AAA/ (as user 3)
and AAA/bbb/ccc was not changed.
and i noticed AAA is owned by user1 and bbb by user 2,
ccc by user 3.
However the permission on all AAA and bbb are already 777, what the heck is
going on? |
|
y***d 发帖数: 2330 | 8 " In contrast, chmod ignores symbolic links encountered during recursive
directory traversals"
type
is |
|
B*********k 发帖数: 3110 | 9 晕,不应该啊。你可能已经试过了:再chmod 777 * 一下? |
|
f****p 发帖数: 18483 | 10 先来个
sudo chmod -r +x *
有了执行权限(x),你就可以cd和ls了。
然后再干别的。 |
|
d*******2 发帖数: 340 | 11 hostmonster的空间,从opencart下载的免费购物车程序2.3.0.2-compiled.zip,将这
个程序上传到public_html/下,在public_html/下解压,然后按照install.txt要求,
将config-dist.php改名为config.php,admin/config-dist.php改名为admin/config.
php,确保一下文件夹可写
chmod 0755 or 0777 system/storage/cache/
chmod 0755 or 0777 system/storage/logs/
chmod 0755 or 0777 system/storage/download/
chmod 0755 or 0777 system/storage/upload/
chmod 0755 or 0777 system/storage/modification/
chmod 0755 or 0777 image/
chmod 0755 or 0777 image/cache/
chmod 0755 or 0777 image/catalo... 阅读全帖 |
|
d*******2 发帖数: 340 | 12 hostmonster的空间,从opencart下载的免费购物车程序2.3.0.2-compiled.zip,将这
个程序上传到public_html/下,在public_html/下解压,然后按照install.txt要求,
将config-dist.php改名为config.php,admin/config-dist.php改名为admin/config.
php,确保一下文件夹可写
chmod 0755 or 0777 system/storage/cache/
chmod 0755 or 0777 system/storage/logs/
chmod 0755 or 0777 system/storage/download/
chmod 0755 or 0777 system/storage/upload/
chmod 0755 or 0777 system/storage/modification/
chmod 0755 or 0777 image/
chmod 0755 or 0777 image/cache/
chmod 0755 or 0777 image/catalo... 阅读全帖 |
|
d*******2 发帖数: 340 | 13 原文安装说明说访问Visit the store homepage e.g. http://www.example.com or http://www.example.com/store/,但实际上是安装到根目录下,根本没有store这个文件夹。访问http://www.mydomain.com的话,还是网站之前的样子,没有看到opencart安装页。先谢了!
These instructions are for a manual installation using FTP, cPanel or other
web hosting Control Panel.
- Linux Install -
1. Upload all of the files and folders to your server from the "Upload"
folder, place them in your web root. The web root is different on some
servers, cPanel it should be public_html/ and on Plesk... 阅读全帖 |
|
p******f 发帖数: 162 | 14
let's say file1 & file2 are in directory ~user0/secret,
and if ~user0, ~user1 & ~user2 are in a single filesystem
you may try this:
user0$ chmod 711 ~ ~/secret
user0$ chmod 644 ~/secret/{file1,file2}
user1$ mkdir ~/secret
user1$ chmod 700 ~/secret
user1$ ln ~user0/secret/{file1,file2} ~/secret
same thing for user2
user0$ chmod 700 ~ (optional)
user0$ chmod 700 ~/secret
user0$ chmod 666 ~/secret/{file1,file2} |
|
a**********0 发帖数: 422 | 15 The Unix Commands
其实就是攒了一下网上的资料
# Create a new tar archive.
# the folder dirname/ is compressed into archive_name.tar
tar cvf archive_name.tar dirname/
# Extract from an existing tar archive
tar xvf archive_name.tar
# View an existing tar archive
tar tvf archive_name.tar
# Search for a given string in a file (case in-sensitive search).
grep -i "the" demo_file
# Print the matched line, along with the 3 lines after it.
grep -A 3 -i "example" demo_text
# Search for a given string in all files recur... 阅读全帖 |
|
m**********e 发帖数: 12525 | 16 【 以下文字转载自 Chicago 讨论区,原文如下 】
发信人: mifepristone (弃婴), 信区: Chicago
标 题: Re: [转载] a UNIX permission question
发信站: Unknown Space - 未名空间 (Tue Jan 25 13:41:53 2005) WWW-POST
unix chmod的两大trick之一,第一个就是这个你说的 “chmod + t”
正式名称是“save program *text* on swap device”,早年计算机
内存不大的时候用的,用于文件,就是文件放到swap device,用于目录,
就是不能删只能写。
chmod的第二大trick就是“chmod + s”,或者叫“set userID”,就是
让其他人有操作你这个文件的权力。
setuid这个东西知道的人比较多,因为这是黑客的最爱。
哈哈。这两招,是甄别unix高低手的准绳
files?
also |
|
m*****x 发帖数: 114 | 17 我在terminal下运行 chmod 777/Users/maiziex/uploads
出现了:
usage: chmod [-fhv] [-R [-H | -L | -P]] [-a | +a | =a [i][# [ n]]] mode|
entry file ...
chmod [-fhv] [-R [-H | -L | -P]] [-E | -C | -N | -i | -I] file ...
但是问题还是一样,不好意思阿,还有别的问题吗? |
|
m*****x 发帖数: 114 | 18 我在terminal下运行 chmod 777/Users/maiziex/uploads
出现了:
usage: chmod [-fhv] [-R [-H | -L | -P]] [-a | +a | =a [i][# [ n]]] mode|
entry file ...
chmod [-fhv] [-R [-H | -L | -P]] [-E | -C | -N | -i | -I] file ...
但是问题还是一样,不好意思阿,还有别的问题吗? |
|
h*w 发帖数: 1182 | 19 抛砖引玉,pogoplug上面可以装很多东西。
本人新手,这个安装说明算是一个备份吧,如果要重新安装可以看看,也可以给新新手
参考。也请高手指点。
为什么没有装arch或者debian是因为看到有人说pogoplug自带的ntfs驱动比ntfs-3g性
能好,就想用原系统加装optware来安装samba共享。而且如果还想用my.pogoplug.com
也可以直接用。还没有实验过到底是自带的ntfs驱动快还是ntfs-3g快,就当瞎折腾了
,呵呵。
本说明基于POGO-E02,不保证在其他版本的pogoplug上也工作。对于使用本安装说明引
起的任何损失概不负责。
------------------------------
1. Find your Pogoplug ip address in your router.
2. Log into your Pogoplug online account that you created during the initial
setup of the POGO. Go into the advanced tab / Security.... 阅读全帖 |
|
h*w 发帖数: 1182 | 20 抛砖引玉,pogoplug上面可以装很多东西。
本人新手,这个安装说明算是一个备份吧,如果要重新安装可以看看,也可以给新新手
参考。也请高手指点。
为什么没有装arch或者debian是因为看到有人说pogoplug自带的ntfs驱动比ntfs-3g性
能好,就想用原系统加装optware来安装samba共享。而且如果还想用my.pogoplug.com
也可以直接用。还没有实验过到底是自带的ntfs驱动快还是ntfs-3g快,就当瞎折腾了
,呵呵。这个主要是给家里只有windowns电脑的用,要是有linux的机器,还是用ext3或
ext4最快。
本说明基于POGO-E02,不保证在其他版本的pogoplug上也工作。对于使用本安装说明引
起的任何损失概不负责。
------------------------------
1. Find your Pogoplug ip address in your router.
2. Log into your Pogoplug online account that you created during the initial
setup... 阅读全帖 |
|
g****g 发帖数: 1828 | 21 thanks. successful!
strange. 我是先在home chmod +x的,然后copy到/usr/local/bin. 刚才到/usr/local
/bin重新 sudo chmod一下,才可以了。也许因为原来的chmod不是用的sudo?anyway
thanks a lot. |
|
|
l******n 发帖数: 17 | 23 /etc/mnttab的属性是这样的:
-r--r--r-- 1 root root
我想编辑这个文件,所以想先加上写权限
没想到 chmod 644 mnttab 改不了,出错
信息是:
#chmod 644 mnttab
chmod: WARNING: can't change mnttab
What's wrong?! 我又试了试其它没有写权限
的都加不上
BTW: 是root, Solaris 8 on SUN ULTRA5 |
|
h*****t 发帖数: 40 | 24 I am not the owner although the files are in my home dir
and the files were generated(uploaded) by board program(users).
I have tried rm,chgrp,chmod,chown. None of them worked.
% rm forum10_f_4.zip
rm: forum10_f_4.zip: override protection 755 (yes/no)? y
rm: forum10_f_4.zip not removed: Permission denied
%
% chgrp "mygroup" forum10_f_4.zip
chgrp: forum10_f_4.zip: Not owner
%
% chmod 777 forum10_f_4.zip
chmod: WARNING: can't change forum10_f_4.zip
%
% chown "me" forum10_f_4.zip
chown: forum10_f_4 |
|
z*********n 发帖数: 94654 | 25 哦,改这个属性啊
chmod 644,如果不在乎安全
chmod 777 |
|
T******e 发帖数: 18290 | 26 你先chmod 777 a.txt
然后再mv
可能你权限不够,所以不让你改名,先chmod |
|
z*********n 发帖数: 94654 | 27 权限不够chmod也不行
得来
sudo chmod 777 a.txt
然后要被问密码 |
|
N**********d 发帖数: 9292 | 28 换到linux下
用root用户对那两个文件执行
chmod a+r grub.con
chmod a+r menu.list |
|
x***q 发帖数: 4953 | 29 http://bbs.feng.com/read-htm-tid-10130023.html
有 mac 的很容易做,
我装了,大概就几分钟时间.
有一点教程里没有的是需要用terminal:
cd /Pods/Target Support Files/Pods/
sudo chmod 777 Pods-resources.sh
sudo chmod 777 Pods-frameworks.sh
需要输一次密码
希望有牛人能改进一下原代码 |
|
m*****x 发帖数: 114 | 30 还有最后一个问题,
在读写文件时,出现问题:
Writing to test2.txt ...
Warning: file_put_contents(test2.txt) [function.file-put-contents]: failed
to open stream: Permission denied in /Applications/XAMPP/xamppfiles/htdocs/
putcontents.php on line 4
Appending to test2.txt ...
Warning: file_put_contents(test2.txt) [function.file-put-contents]: failed
to open stream: Permission denied in /Applications/XAMPP/xamppfiles/htdocs/
putcontents.php on line 6
也是permission的问题,我所有的.php和相关的东西都在/Applications/XAMPP/
xamppfiles/htdocs下... 阅读全帖 |
|
m*****x 发帖数: 114 | 31 还有最后一个问题,
在读写文件时,出现问题:
Writing to test2.txt ...
Warning: file_put_contents(test2.txt) [function.file-put-contents]: failed
to open stream: Permission denied in /Applications/XAMPP/xamppfiles/htdocs/
putcontents.php on line 4
Appending to test2.txt ...
Warning: file_put_contents(test2.txt) [function.file-put-contents]: failed
to open stream: Permission denied in /Applications/XAMPP/xamppfiles/htdocs/
putcontents.php on line 6
也是permission的问题,我所有的.php和相关的东西都在/Applications/XAMPP/
xamppfiles/htdocs下... 阅读全帖 |
|
b**********i 发帖数: 1482 | 32 因为win下编成的sh文件跟bt3下写成的不同,经过几次修改,最后的情况是运行之后就
死在那里,我用了只有5个tracking#的小样本。
root@bt:/# chmod +x usps.sh
root@bt:/# /usps.sh number1.txt track.txt
-bash: /usps.sh: /bin/sh^M: bad interpreter: 没有那个文件或目录
root@bt:/# chmod +x usps1.sh
root@bt:/# /usps1.sh number1.txt track.txt
/usps1.sh: line 8: syntax error near unexpected token `|'
/usps1.sh: line 8: `| grep showAddress | head -n 1 | cut -f 2 -d '"' 2> /dev
/null'
root@bt:/# /usps1.sh number1.txt track.txt |
|
w***w 发帖数: 1552 | 33 不行啊。用root账号执行chmod,出错,
chmod: 更改 “/etc/network/interfaces” 的权限: 只读文件系统
好像是整个系统成了个只读系统了 |
|
d**o 发帖数: 864 | 34 用chmod 将 var/www改成你的用户名可写的就可以了.
这也是linux好的一方面,权限管理清楚.
搜索一下chmod怎么用. |
|
|
y***j 发帖数: 11235 | 36 原来用e3000加上神座dockstar,神座上挂一个网络硬盘,和一个打印机,另外
asterisk+gv做家里的电话,phone adapter用的pap2。最近有了老二准备吧神座折腾成
babymonitor,就要放到楼上。e3000又没法同时挂硬盘和打印机。正好有这个22刀(
btw:大家shopper的cb通知了么?)的地沟由(Belkin Share Max N300 Wireless N+ Router, model # F7D7301 which is a rebadged F7D3301).的deal就进了一个。基本上有线拷贝东西
7M左右还凑合跟e3000一样,好像覆盖范围比e3000差点儿?但是能覆盖我的乳房了。无
线拷贝的速度还没测试。
现在我的垃圾由装了西红柿,带一块硬盘,一个打印机,另外开asterisk。
——————ddwrt——————
1.下载ddwrt:http://www.dd-wrt.com/dd-wrtv2/downloads/others/eko/V24-K26/svn15396/dd-wrt.v24-15396_NEWD-2_K2.6_mi... 阅读全帖 |
|
d****n 发帖数: 12461 | 37 ☆─────────────────────────────────────☆
yddmj (yddmj) 于 (Fri Apr 20 16:13:54 2012, 美东) 提到:
原来用e3000加上神座dockstar,神座上挂一个网络硬盘,和一个打印机,另外
asterisk+gv做家里的电话,phone adapter用的pap2。最近有了老二准备吧神座折腾成
babymonitor,就要放到楼上。e3000又没法同时挂硬盘和打印机。正好有这个22刀(
btw:大家shopper的cb通知了么?)的地沟由(Belkin Share Max N300 Wireless N+ Router, model # F7D7301 which is a rebadged F7D3301).的deal就进了一个。基本上有线拷贝东西
7M左右还凑合跟e3000一样,好像覆盖范围比e3000差点儿?但是能覆盖我的乳房了。无
线拷贝的速度还没测试。
现在我的垃圾由装了西红柿,带一块硬盘,一个打印机,另外开asterisk。
——————ddwrt——————
1.下载ddwrt:http... 阅读全帖 |
|
l*******e 发帖数: 3584 | 38 security=user
这句我在CONF里有,
改来改去的,没有了[global]
但应该不影响吧,在第CONF里的第一行。
就是不停地叫我输入密码,说是不对。
# chmod a+rx /smaba -R
chmod: cannot access `/smaba': No such file or directory
可能已经装乱了,怎么出了这个了。 |
|
s***d 发帖数: 960 | 39 ARCHLINUX 按照以下步骤装成了
Pogoplug v2 (Pink/Gray)
Overview
Installation
VERIFY YOUR MODEL NUMBER! These instructions only apply to models POGO-
E02 and POGO-E02G.
These instructions will void your warranty. While every precaution is
taken to ensure nothing bad happens, all actions are at your own risk.
my.pogoplug.com, the mobile applications, and the desktop Pogoplug
connector will no longer work.
With the device on and online, attempt to SSH to the IP the device
received thro... 阅读全帖 |
|
e*****t 发帖数: 1005 | 40 先chmod 777,看看能不能解决问题
chmod
示~
Permissi
我在 |
|
wy 发帖数: 14511 | 41 try
chmod 700 .ssh
chmod 600 .ssh/authrized_keys |
|
Z****e 发帖数: 2999 | 42 This is what I tried:
first, need setuid on screen:
sudo chmod +s /usr/bin/screen
sudo chmod 755 /var/run/screen
on test1 account, this is the .screenrc:
multiuser on
addacl test2
then with test2 account, do:
$ screen -S test1/[PID] -r |
|
c******a 发帖数: 159 | 43 要让老板拷我的一堆文件。我是owner。老板是网络group内的。默认文件拷过去权限都
是executable的,但事实上文件只是text file。所以每次双击打开都报错。我想改权
限为non-executable for group。我用chmod -R 766 foldername该后,老板没法访问
。若用chmod -R 755 foldername老板可以访问,但文件又是executable的了。
我该用什么命令解决问题呢?多谢大侠赐教。 |
|
|
n****e 发帖数: 6292 | 45 你是加载之后chmod,还是加载之前chmod? |
|