URGENT - untar files

Posted on 2012-09-13
Last Modified: 2012-09-13
In HP-UX O.S. I have directory 817_file with n files

I created this tar:
tar -cvf /opt/ora817/ora817_product_817_817_file.tar 817_file

Now I need untar these file into /opt/ora817/product/817

If I run:
cd /opt/ora817/product/817

tar -xvf /opt/ora817/ora817_product_817_817_file.tar

I get /opt/ora817/product/817/817_file directory but I need only the files into /opt/ora817/product/817

Have you anydea which steps I perform?
Question by:ralph_rea
    LVL 68

    Expert Comment

    cd to 817_file befor creating the archive.

    Use a dot as a source specifier then:

    cd 817_file
    tar -cvf /opt/ora817/ora817_product_817_817_file.tar .

    Author Comment

    I haven't more the 817_file directory but only the tar ora817_product_817_817_file.tar

    How Can I untar or copy or move these file into /opt/ora817/product/817?
    LVL 68

    Accepted Solution

    cd /opt/ora817/product/817
    mv 817_file/* .
    rmdir 817_file

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Join & Write a Comment

    If you have a server on collocation with the super-fast CPU, that doesn't mean that you get it running at full power. Here is a preamble. When doing inventory of Linux servers, that I'm administering, I've found that some of them are running on l…
    SSH (Secure Shell) - Tips and Tricks As you all know SSH(Secure Shell) is a network protocol, which we use to access/transfer files securely between two networked devices. SSH was actually designed as a replacement for insecure protocols that sen…
    This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
    Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

    746 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    14 Experts available now in Live!

    Get 1:1 Help Now