Solved

Unix command problem

Posted on 2012-03-19
8
475 Views
Last Modified: 2012-03-25
following in UNIX operating system using the UNIX commands
Create three files with at least a paragraph of text. Print these three files using minimum number of UNIX commands.

Create a directory. Change its permission to Read only. Now try to copy a file in this directory. Record the outcome of the operation and explain it.(in unix)
0
Comment
Question by:xeroxzerox
8 Comments
 
LVL 40

Expert Comment

by:omarfarid
Comment Utility
Is this a homework?
0
 
LVL 6

Author Comment

by:xeroxzerox
Comment Utility
if this is homework i'm not asking this question in here.
0
 
LVL 40

Expert Comment

by:omarfarid
Comment Utility
What commands you tried?
0
 
LVL 6

Author Comment

by:xeroxzerox
Comment Utility
If i know why i'm asking...
0
What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 
LVL 37

Assisted Solution

by:Gerwin Jansen
Gerwin Jansen earned 250 total points
Comment Utility
Depending a bit on which UNIX version you have, printing through cups for example is just as simple as this:

lp <filename>

When printing more that one file, just create a basic loop like this:

for file in file1 file2 file3; do lp ${file}; done;

And for your directory question, create it using mkdir <directory>, set to read only by removing the write permissions using chmod -w <directory>, try copying a file to it using cp <file> <directory>/ - use your terminal output as a starter for explaining what is happening.

Pls. try and post your experiences and feedback :)
0
 
LVL 61

Assisted Solution

by:gheist
gheist earned 250 total points
Comment Utility
echo * | xargs -n1 lp
0
 
LVL 6

Accepted Solution

by:
xeroxzerox earned 0 total points
Comment Utility
Thanks for your support,
ans1: quep-c name' name project.txt
ans2: create directory
MK DIR
Syntax mkdir[options] directory name
0
 
LVL 6

Author Closing Comment

by:xeroxzerox
Comment Utility
I have find right solution for this question.
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
Why Shell Scripting? Shell scripting is a powerful method of accessing UNIX systems and it is very flexible. Shell scripts are required when we want to execute a sequence of commands in Unix flavored operating systems. “Shell” is the command line i…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

743 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

15 Experts available now in Live!

Get 1:1 Help Now