ºìÁªLinuxÃÅ»§
Linux°ïÖú
µ±Ç°Î»ÖÃ: ºìÁªLinuxÃÅ»§ > Debian

ÓÉÓÚȨÏÞÎÊÌâ²»³É¹¦µÄתÒÆ·ÖÇø¡££¨Òѽâ¾ö£¬Ê¹ÓÃcp -a)

·¢²¼Ê±¼ä:2009-04-09 14:06:54À´Ô´:ºìÁª×÷Õß:Áõ³å
[i=s] ±¾Ìû×îºóÓÉ Áõ³å ÓÚ 2009-4-10 15:21 ±à¼­ [/i]

ÏÖÔÚ·¢ÏÖ£¬tar²ÅÄÜÐС£cpÊDz»Ðеģ¬»á¸ü¸ÄȨÏÞ£¬¶øtarÄܱ£³ÖȨÏÞ¡£
»òÕßʹÓÃ[color=Blue] cp -a À´×ªÒÆÎļþµ½Ð·ÖÇø[/color]
¼ÌÐø̽Ë÷¡­¡­

Ô­ÎÄÈçÏ£º
ÓÉÓÚ¿ªÊ¼µÄʱºò·ÖÇø²»ÊǺܺÏÊÊ£¬ÏÖÔÚ¸ùĿ¼¿ìÂúÁË£¬ÓÚÊÇÖØл®·ÖÁËÒ»¸öеĴó·ÖÇø£¬½«ÎļþתÒƹýÈ¥¡£
ÔÚrootÏÂÖ±½Ó½«Òª×ªÒƵÄÎļþ¸´ÖƵ½Ð·ÖÇø£¬È»ºó¸ü¸Ä/boot/grub/menu.lstÓë/etc/fstab£¬ÖØÆô£¬°²×°grubµ½Ð·ÖÇø£¬Æô¶¯³É¹¦¡£:0wmjh(1

Æô¶¯ºóÒ»ÇÐÕý³££¬µ«Êǵ±ÎÒʹÓÃsuduÒÔ¼°suµÄʱºò£¬¾Í³öÏÖ¹ÊÕÏÁË£º
sudo: must be setuid root
su£º¼ø¶¨¹ÊÕÏ(5ty(
»¹ÓоÍÊÇ£¬gnomeÏÂÄÇЩҪÇóÊäÈëÃÜÂë²ÅÄÜÖ´ÐеÄÌØȨÉèÖóÌÐò¶¼²»ÐÐÁË
ÊäÈë¸ùÓû§ÃÜÂëºó´°¿ÚÁ¢¼´¹Ø±Õ¡£
¿ØÖÆֱ̨½ÓµÇ¼rootÓû§Ò»ÇÐÕý³££¬suÒ²ÐУ¬sudoÒ²ÐУ¬ÆÕͨÓû§²»ÐУ¨Ô­À´ÒѾ­ÅäÖúÃÁ˵ģ¬ÏÖÔÚÎÒ¿´/etc/sudoersÒ²ÊÇÕý³££©¡£
ÇëÎÊÕâÊÇʲôԭÒò£¿

sudo½â¾öÁË
chmod 4755 /usr/bin/sudo

su»¹ÊÇûÓнâ¾ö¡£
ÍøÉÏûÓÐÕÒµ½°ì·¨£¬ÎÒ×Ô¼ºÏëÁËÏ£¬¹À¼Æ¸úsudo²î²»¶à£¬ËùÒÔÖ´ÐÐ
which su
ÕÒµ½suµÄλÖúó
chmod 4755 /bin/su

´ó¹¦¸æ³É£¡
¾ÍÊDz»ÖªµÀ»¹»áÓÐʲôÅäÖôíÎҵȴýÎÒÈ¥¸ü¸Ä£¡):o:s

ÏÖÔÚ·¢ÏÖ£¬ÊÇÓÉÓÚ¸´ÖƵÄʱºòÎļþ¸´ÖÆÁË£¬È¨ÏÞÈ´¸úÔ­À´²»Ò»ÑùÁË¡£
ls -l /binÒÔ¼°/usr/bin¿´µ½£¬¸úÔ­À´µÄ²»Ò»Ñù£¡
ÇëÎÊÔõôÄܸü¸Ä³É¸úÔ­À´µÄÏàͬȨÏÞ£¿
ÎÄÕÂÆÀÂÛ

¹²ÓÐ 6 ÌõÆÀÂÛ

  1. Áõ³å ÓÚ 2009-04-10 15:19:39·¢±í:

    ÎÒʹÓÃÁËcp -a ³É¹¦×ªÒÆÁË·ÖÇø£¬Ò»ÇÐÕý³£¡£

  2. marco.chan ÓÚ 2009-04-09 16:04:35·¢±í:

    ×÷Õß: Ïà˼°®ÎÄ ·¢²¼ÈÕÆÚ: 2009-4-09
    ¼Ó²ÎÊý-p
    £­£­£­ÕâλÐֵܲÅÊÇÕý½â£¡-p²ÎÊý±íʾ±£³ÖÔ­ÓÐÊôÐÔ¡£
    http://www.im321.com/blog/article.asp?id=166 ¿´ÕâÌû×Ó£¬ÀïÃæÓÐÌáµ½Õâ¸ö²ÎÊý£¡

  3. Ïà˼°®ÎÄ ÓÚ 2009-04-09 15:53:43·¢±í:

    ¼Ó²ÎÊý-p

  4. Áõ³å ÓÚ 2009-04-09 15:19:49·¢±í:

    Ŷ£¬ÎÒÃ÷°×ÁË£¬ÊÇÓÃcp¸´ÖÆÊDz»Ðеģ¡
    Ó¦¸ÃÓÃtar£¬¿ÉÒÔ±£³ÖȨÏ޵ġ£
    ¼ÌÐø̽Ë÷¡­¡­

  5. Áõ³å ÓÚ 2009-04-09 14:40:46·¢±í:

    su½â¾ö£¡
    ÍøÉÏûÓÐÕÒµ½°ì·¨£¬ÎÒ×Ô¼ºÏëÁËÏ£¬¹À¼Æ¸úsudo²î²»¶à£¬ËùÒÔÖ´ÐÐ
    which su
    ÕÒµ½suµÄλÖúó
    chmod 4755 /bin/su

    ´ó¹¦¸æ³É£¡
    ¾ÍÊDz»ÖªµÀ»¹»áÓÐʲôÅäÖôíÎҵȴýÎÒÈ¥¸ü¸Ä£¡):o:s

  6. Áõ³å ÓÚ 2009-04-09 14:36:46·¢±í:

    sudo½â¾öÁË
    chmod 4755 /usr/bin/sudo

    su»¹ÊÇûÓнâ¾ö¡£