Find the answer to your Linux question:
Results 1 to 8 of 8
What commands would i have to put into a konsole to create a tarball (.tar.bz2 and .tar.bz)...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Linux Newbie
    Join Date
    Feb 2004
    Location
    UK
    Posts
    131

    Making a tarball


    What commands would i have to put into a konsole to create a tarball (.tar.bz2 and .tar.bz)

  2. #2
    Linux Guru dylunio's Avatar
    Join Date
    Aug 2004
    Location
    Cymru
    Posts
    4,157
    Use the tar command:

    for tar.gz:
    Code:
    tar cvzf tarfile.tar.gz files...
    for tar.bz2:
    Code:
    tar cvjf tarfile.tar.bz2 files...
    I hope this helps

    dylunio
    Registered Linux User #371543!
    Get force-get May The Source Be With You
    /dev/null
    /dev/null2

  3. #3
    Linux Newbie
    Join Date
    Feb 2004
    Location
    UK
    Posts
    131
    How would i go about compressing the sub-folders and files. This will do 1 specific file (OR folder) what should i add to do all the folders within a folder

  4. #4
    Linux Guru dylunio's Avatar
    Join Date
    Aug 2004
    Location
    Cymru
    Posts
    4,157
    I'm not sure whay you are asking, you can try, if you have a file named foo within a directory named foo:
    Code:
    cd foo
    tar cvzf tarfile.tar.gz foo
    cd ~
    tar cvzf tarfile.tar.gz foo
    I'm sure there is a faster way of doing this though....
    Registered Linux User #371543!
    Get force-get May The Source Be With You
    /dev/null
    /dev/null2

  5. #5
    Linux Newbie
    Join Date
    Feb 2004
    Location
    UK
    Posts
    131
    I want to compress a directory which has several sub directories all together in one tarball

    Is that possible?

  6. #6
    Linux Guru dylunio's Avatar
    Join Date
    Aug 2004
    Location
    Cymru
    Posts
    4,157
    The first command did that I think, at least I have got it to do that, with
    Code:
    tar cvzf home.tar.gz /home/dylunio
    , and I have conpressed my whole /home/dylunio with all my sub dirs with it.

    or didn't this happen?
    Registered Linux User #371543!
    Get force-get May The Source Be With You
    /dev/null
    /dev/null2

  7. #7
    Linux Newbie
    Join Date
    Feb 2004
    Location
    UK
    Posts
    131
    Thank you, first time i done it it seemed to have no files in and was 93kb, i have tried again and it works perfectly

    I tried using arK but it was just too unstable compaired to using the konsole.

    once again
    THANKS

  8. #8
    Linux Guru dylunio's Avatar
    Join Date
    Aug 2004
    Location
    Cymru
    Posts
    4,157
    I'm glad you have got it working
    Registered Linux User #371543!
    Get force-get May The Source Be With You
    /dev/null
    /dev/null2

Posting Permissions

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