• RH033读书笔记(3)-Lab 4 Browsing the Filesystem


    Lab 4 Browsing the Filesystem

    Sequence 1: Directory and File Organization

    1. Log in as user student with the password student.

    2. [student@stationX ~]$ pwd
    /home/student

    3. ls
        ls -a
        ls -al
    -a option includes files whose names begin with a period and used for storing configuration information
    The fifth column of ls -l's output displays the file's size.

    4. [student@stationX ~]$ touch {report,graph}_{jan,feb,mar}

    5. [student@stationX ~]$ ls

    6. Make directory
    [student@stationX ~]$ mkdir Projects
    [student@stationX ~]$ mkdir Projects/graphs
    [student@stationX ~]$ cd Projects
    [student@stationX Projects]$ mkdir reports
    [student@stationX Projects]$ cd reports
    [student@stationX reports]$ mkdir ../Backups

    [student@stationX reports]$ cd
    [student@stationX ~]$ ls -l
    [student@stationX ~]$ ls Projects

    7. Move files
    [student@stationX ~]$ mv graph_jan Projects/graphs
    [student@stationX ~]$ mv graph_feb graph_mar Projects/graphs
    [student@stationX ~]$ ls -l Projects/graphs/

    8. Move the files in one command:
    [student@stationX ~]$ mv report_jan report_feb Projects/reports
    [student@stationX ~]$ ls -l Projects/reports

    9. Remove the remaining report file:
    [student@stationX ~]$ rm report_mar
    [student@stationX ~]$ ls

    10. Copy one using an absolute pathname and the other using a relative pathname:
    [student@stationX ~]$ cd Projects/Backups
    [student@stationX Backups]$ pwd

    [student@stationX Backups]$ cp ../reports/report_jan .
    [student@stationX Backups]$ cp /home/student/Projects/graphs/graph_jan .
    [student@stationX Backups]$ ls -l

    11. exit

    Sequence 2: Managing Files with Nautilus

    1. If you have not already, log into the graphical environment.

    2. Double-click on the student's Home icon on your desktop.

    3. Double-click on Projects, then graphs.

    4. With the graphs window selected, press Ctrl-Shift-w to close the parent directory windows.

    5. Press Ctrl-a to select all three graphs.

    6. Press Ctrl-c to copy the files.

    7. Press Ctrl-l (the letter l, not the number 1) to display the Open Location dialog. Type /tmp
    (note that you can use tab-completion) and press Enter to open a new window displaying /
    tmp.

    8. Press Ctrl-Shift-n or right-click on the window background and select Create Folder to
    create a new directory.

    9. Type in Stuff_for_Bob as the new directory's name and double-click the directory to
    open it

    10. Press Ctrl-v to paste your graphs into /tmp/Stuff_for_Bob.

    11. Press Ctrl-q to close all Nautilus windows

    Sequence 3: Backing-up your system configuration

    1. Log in on tty1 as user root with the password of redhat.

    2. [root@stationX ~]# mkdir ~/backups

    3. recursively copy
    cp -rpv /etc/sysconfig ~/backups/sysconfig-20071231
    cp -av /etc/sysconfig ~/backups/sysconfig-20071231

    4. cp -av /etc/sysconfig ~/backups/sysconfig-20071231
    ~/backups/sysconfig-20071231/sysconfig/

    5. cp -av /etc/sysconfig ~/backups/sysconfig-20071231
    be prompted for confirmation before overwriting

  • 相关阅读:
    水晶报表参数字段在代码中赋值
    存储过程编写经验和优化措施
    积分与排名
    大话处理器
    抽象数学
    开普勒:天空的立法者
    Scalable Face Image Retrieval with IdentityBased Quantization and Multireference Reranking
    配色辞典
    图像识别顶级赛事
    Information Geometry
  • 原文地址:https://www.cnblogs.com/thlzhf/p/3437377.html
Copyright © 2020-2023  润新知