欢迎来到淘文阁 - 分享文档赚钱的网站! | 帮助中心 好文档才是您的得力助手!
淘文阁 - 分享文档赚钱的网站
全部分类
  • 研究报告>
  • 管理文献>
  • 标准材料>
  • 技术资料>
  • 教育专区>
  • 应用文书>
  • 生活休闲>
  • 考试试题>
  • pptx模板>
  • 工商注册>
  • 期刊短文>
  • 图片设计>
  • ImageVerifierCode 换一换

    《aix系统应用基础》04filesandd.ppt

    • 资源ID:72526537       资源大小:336.50KB        全文页数:25页
    • 资源格式: PPT        下载积分:11.9金币
    快捷下载 游客一键下载
    会员登录下载
    微信登录下载
    三方登录下载: 微信开放平台登录   QQ登录  
    二维码
    微信扫一扫登录
    下载资源需要11.9金币
    邮箱/手机:
    温馨提示:
    快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。
    如填写123,账号就是123,密码也是123。
    支付方式: 支付宝    微信支付   
    验证码:   换一换

     
    账号:
    密码:
    验证码:   换一换
      忘记密码?
        
    友情提示
    2、PDF文件下载后,可能会被浏览器默认打开,此种情况可以点击浏览器菜单,保存网页到桌面,就可以正常下载了。
    3、本站不支持迅雷下载,请使用电脑自带的IE浏览器,或者360浏览器、谷歌浏览器下载即可。
    4、本站资源下载后的文档和图纸-无水印,预览文档经过压缩,下载后原文更清晰。
    5、试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。

    《aix系统应用基础》04filesandd.ppt

    Course materials may not be reproduced in whole or in part without the prior written permission of IBM.5.04.1 Unit 4 Files and Directories Copyright IBM Corporation 2008Unit ObjectivesAfter completing this unit,you should be able to:Describe the different file typesDescribe the AIX file system structureUse full and relative path names in a file specificationCreate,delete,and list directoriesUse the touch command to create an empty file Copyright IBM Corporation 2008A FileA file is:A collection of dataA stream of characters or a byte streamNo structure is imposed on a file by the operating system Copyright IBM Corporation 2008File TypeslOrdinary:Text or code datalDirectory:A table of contents,that stores a list of files within thatdirectorylSpecial Files:Represent hardware or logical devicesExample:The CD-ROM device is accessed via the/dev/cd0 file.Copyright IBM Corporation 2008#typemodelinksusergroupdatesizeloc4dir7552team01staffJuly 10 10:1551210file6441team01staffJuly 11 11:00 96namei-nodesubdir14myfile10Directoryi-node TableData$vi myfileDirectory Contents Copyright IBM Corporation 2008AIX File SystemsRefers to both the physical and logical storage and access of files.In AIX,a file system is an allocation of storage.Similar in concept to partitions in the PC environment.Allows the operating system to store and retrieve the data from files quickly and efficiently.To access file systems,we associate them with a directory.AIX has several pre-defined file systems:/(root)/tmp/usr/opt/var/home/proc Copyright IBM Corporation 2008/usrdevhomesbinetcvartty1lp0suba.profilemanualstest1mon_reporttrio_ltrwalrusteam01team02team03testcdoccreportspgmsbinproc tmpoptHierarchical Structure Copyright IBM Corporation 2008Path NameslA sequence of names,separated by slashes(/),that describes the path the system must follow to locate a file in the file system.lThere are two types of path names:Absolute or Full Path Name(start from the/directory):lRelative Path Name(start from current directory):$vi/home/team01/doc/mon_report$/usr/bin/ls l/home/team01$cd/home/team01$vi doc/mon_report$cd/usr/bin$./ls l/home/team01 Copyright IBM Corporation 2008Where Am I?lThe print working directory command can be used to find out what your current directory is:$pwd/home/team01 Copyright IBM Corporation 2008Common options:-a:Show hidden files(files that start with a“.”)-R:List files in all subdirectories(recursively)Syntax:ls directory Listing Directories$lsc doc manuals test1$ls a.profile c doc manuals test1$ls Rc doc manuals test1./c:./doc:Mon_report trio_ltr walrus Copyright IBM Corporation 2008The ls command with the-l option can be used to obtain more information about the files in a directory.Long Listing of Files$ls ltotal 5drwxrwxr-x2 team01 staff 1024 Aug 12 10:16 cdrwxrwxr-x2 team01 staff 512 Feb 18 09:55 doc-rwxrwxr-x1 team01 staff 320 Feb 22 07:30 suba-rwxrwxr-x2 team01 staff 144 Feb 22 16:30 test1$ls li test129-rwxrwxr-x 2 team01 staff 144 Feb 22 16:30 test1 Copyright IBM Corporation 2008Set the current working directory from/home/team01 to/home/team01/doc:Set your working directory to your home directory:Set your working directory to the parent directory:Syntax:cd directory Change Current Directory$cd docrelative path$cd/home/team01/docfull path$cd$cd.Copyright IBM Corporation 2008Activity:Q+A1.How can you determine the i-node number of a file?2.Where are the names and i-node numbers of files stored?3.How can you determine your current directory?4.How can you list all files in a directory,including hidden files?5.Your current directory is/usr/dt/bin.What is the easiest way to change to your home directory?6.Which file names are relative(check all that apply)?q./team03/dir1q/tmp/file1q/.profileq./.profile7.Write down the three different file types that AIX knows:1.2.3.Copyright IBM Corporation 2008To create the directory test,as a sub-directory of/home/team01:(or)Syntax:mkdir directory Creating Directories$mkdir/home/team01/testfull path name$cd/home/team01$mkdir testrelative path name Copyright IBM Corporation 2008Remove the directory/home/team01/test:Syntax:rmdir directory The directory must be empty!Removing Directories$rmdir/home/team01/test$rmdir docrmdir:Directory doc is not empty.Copyright IBM Corporation 2008home/team01dir1home/team01dir2dir3Working with Multiple DirectorieslCreate multiple directories simultaneously:$mkdir-p dir1/dir2/dir3lRemove all directories in the path specified:$rmdir-p dir1/dir2/dir3 Copyright IBM Corporation 2008Displaying Directory Information$ls-ldi mydir51 drwxr-xr-x 2 team01 staff 512 Jan 17 17:38 mydir$istat mydirInode 51 on device 10/8 DirectoryProtection:rwxr-xr-xOwner:208(team01)Group:1(staff)Link count:2 Length 512 bytesLast updated:Thu Jan 17 21:05:43 2002Last modified:Thu Jan 17 17:38:52 2002Last accessed:Fri Jan 18 13:30:00 2002$Copyright IBM Corporation 2008AIX File NamesShould be descriptive of the contentShould use only alphanumeric characters:UPPERCASE,lowercase,number,#,_Should not include imbedded blanksShould not contain shell metacharacters:*?/;&!|$()Should not begin with+or-signShould not be the same as a system commandAre case-sensitiveFile names starting with a.(dot)are hidden from the normal ls commandThe maximum number of characters for a file name is 255 Copyright IBM Corporation 2008touch CommandThe touch command updates the access and modification times of a file.The command can also be used to create zero-length files.$ls-l-rwxrwxr-x 1 team01 staff 320 Jan 6 07:30 suba$dateTues Sep 10 12:25:00 2002$touch suba new_file$ls-l-rwxrwxr-x 1 team01 staff 320 Sep 10 12:25 suba-rw-r-r-1 team01 staff 0 Sep 10 12:25 new_file Copyright IBM Corporation 2008Checkpoint(1 of 2)1.Using the tree structure shown earlier,and using/home as your current directory,how would you refer to the suba file in the pgms directory using both full and relative path names?2.When specifying a path name,what is the difference between the.and the.?3.What will the cd./.command do?4.What conditions have to be satisfied in order for the rmdir command to complete successfully?Copyright IBM Corporation 2008Checkpoint Solutions(1 of 2)1.Using the tree structure shown earlier,and using/home as your current directory,how would you refer to the suba file in the pgms directory using both full and relative path names?Relative path name:team03/pgms/subaFull path name:/home/team03/pgms/suba2.When specifying a path name,what is the difference between the.and the.?.Specifies current directory.Specifies parent directory3.What will the cd./.command do?Change your current working directory two directories higher.4.What conditions have to be satisfied in order for the rmdir command to complete successfully?1.The directory must be empty.2.You must be at least one directory level higher that the one you are trying to remove.Copyright IBM Corporation 2008Checkpoint(2 of 2)5.Match the various options of the ls command with their functions.-a_Provides a long listing of files-i_Lists hidden files-d_Lists subdirectories and their contents recursively-l_Displays the i-node number-R_Displays information about a directory6.Circle the following valid file names in the following list:1 aBcDe -myfile my_file my.file my file .myfile Copyright IBM Corporation 2008Checkpoint Solutions(2 of 2)5.Match the various options of the ls command with their functions.-a-l Provides a long listing of files-i-a Lists hidden files-d-R Lists subdirectories and their contents recursively-l-i Displays the i-node number-R-d Displays information about a directory6.Circle the following valid file names in the following list:1 aBcDe -myfile my_file my.file my file .myfile Copyright IBM Corporation 2008Exercise:Files and Directories Copyright IBM Corporation 2008Unit Summary There are three types of files which are supported:OrdinaryDirectorySpecialThe AIX file system structure is a hierarchical tree.Files are accessed using either full or relative path names.A path name always begins with a/(forward slash).The following commands can be used with directories:pwd,cd,mkdir,rmdir,and ls.Copyright IBM Corporation 2008

    注意事项

    本文(《aix系统应用基础》04filesandd.ppt)为本站会员(wuy****n92)主动上传,淘文阁 - 分享文档赚钱的网站仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知淘文阁 - 分享文档赚钱的网站(点击联系客服),我们立即给予删除!

    温馨提示:如果因为网速或其他原因下载失败请重新下载,重复下载不扣分。




    关于淘文阁 - 版权申诉 - 用户使用规则 - 积分规则 - 联系我们

    本站为文档C TO C交易模式,本站只提供存储空间、用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。本站仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知淘文阁网,我们立即给予删除!客服QQ:136780468 微信:18945177775 电话:18904686070

    工信部备案号:黑ICP备15003705号 © 2020-2023 www.taowenge.com 淘文阁 

    收起
    展开