Find the answer to your Linux question:
Results 1 to 6 of 6
I have an old server, has a few sda partitions one of these partitions (/dev/sda6 12G 12G 0 100% /var) is 100% full. How do I list/get to files on ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Dec 2012
    Posts
    24

    Newbie question: finding files on specific sda drive?


    I have an old server,
    has a few sda partitions
    one of these partitions (/dev/sda6 12G 12G 0 100% /var) is 100% full.

    How do I list/get to files on this (and only this) partition/drive? I want to go there and run something like du -hc --max-depth=1 to list the file sizes and see what's eating up the space.

    Thanks!!

  2. #2
    Linux Guru Lazydog's Avatar
    Join Date
    Jun 2004
    Location
    The Keystone State
    Posts
    2,672
    Try the following comand and see if that does what you want to do.
    Code:
    ls -alR
    If it is a big list you might need to pipe the output through less or into a file.

    Regards
    Robert

    Linux
    The adventure of a life time.

    Linux User #296285
    Get Counted

  3. #3
    Just Joined!
    Join Date
    Dec 2012
    Posts
    24
    But how do i see only the files on the "/dev/sda6" drive?

  4. #4
    Linux Guru Lazydog's Avatar
    Join Date
    Jun 2004
    Location
    The Keystone State
    Posts
    2,672
    How about Change Directory? Just CD to the mount point and run the command.

    Regards
    Robert

    Linux
    The adventure of a life time.

    Linux User #296285
    Get Counted

  5. #5
    Just Joined!
    Join Date
    Dec 2012
    Posts
    24
    doesnt work

    sda6 is not a folder but mounted disk / partition , like /dev/sda1 , /dev/sda5, etc.

    server:/ # cd sda6
    -bash: cd: sda6: No such file or directory
    serve:/ # cd /dev/sda6
    -bash: cd: /dev/sda6: Not a directory
    serve:/ # cd dev/sda6
    -bash: cd: dev/sda6: Not a directory
    serve:/ #

  6. #6
    Just Joined!
    Join Date
    Dec 2012
    Posts
    24
    Quote Originally Posted by Being View Post
    doesnt work

    sda6 is not a folder but mounted disk / partition , like /dev/sda1 , /dev/sda5, etc.

    server:/ # cd sda6
    -bash: cd: sda6: No such file or directory
    serve:/ # cd /dev/sda6
    -bash: cd: /dev/sda6: Not a directory
    serve:/ # cd dev/sda6
    -bash: cd: dev/sda6: Not a directory
    serve:/ #

    never mind,

    looking at this

    /dev/sda6 12G 12G 0 100% /var

    simply CD into var

    the full drive is where the var folder lives.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •