asit pal


{ City } kolkata
< Country > india
* Profession * software engineer
User No # 39070
Total Questions Posted # 3
Total Answers Posted # 10

Total Answers Posted for My Questions # 7
Total Views for My Questions # 17970

Users Marked my Answers as Correct # 26
Users Marked my Answers as Wrong # 29
Questions / { asit pal }
Questions Answers Category Views Company eMail

Where cron file kept?

Tech Mahindra,

2 Shell Script 6194

In a single command how do you run the previous command in the command prompt.

5 Shell Script 7562

Pls let me know the training centre of ISTQB Certification at KOLKATA- asitp2001@gmail.com

ISTQB Certification 4214




Answers / { asit pal }

Question { 31303 }

what is the command to find out which shell you are running?


Answer

which shell

Is This Answer Correct ?    0 Yes 12 No

Question { 31303 }

what is the command to find out which shell you are running?


Answer

[Admin@RSPC985 Asit]$ which $SHELL
/bin/bash

Is This Answer Correct ?    3 Yes 3 No


Question { 10881 }

what is tar command and what are the different types of tar
commands?


Answer

tar is used for both zip and unzip the files or directories
in unix.
tar cvzf zip_file.tar zip_file
tar xvzf zip_file.tar

Is This Answer Correct ?    1 Yes 0 No

Question { 11752 }

If you have a string "one two three", which shell command
would you use to extract the strings?


Answer

echo $a | tr " " "\n" | head -1
echo $a | tr " " "\n" | head -2
echo $a | tr " " "\n" | head -3

Is This Answer Correct ?    2 Yes 1 No

Question { 5859 }

How to make userdefined variables to available for all
other shells?


Answer

for Global declaration::
setenv x 10
setenv str "test"
for local declaration::
set a = 10
set s = "test"

Is This Answer Correct ?    0 Yes 0 No

Question { 6529 }

How to take input values from the user?


Answer

set x = $<

Is This Answer Correct ?    2 Yes 2 No

Question { IBM, 9752 }

How do you print the output the same string which is typed
in command line. how do you write the shell script or
command for this. if i entered "Hello" in command line, it
should print 'Hello', if i say "Hello Welcome", i should get
the "Hello Welcome" as output.?


Answer

echo "$*"

Is This Answer Correct ?    1 Yes 0 No

Question { Nokia, 183108 }

How do you create a file in UNIX


Answer

vi filename.extension

Is This Answer Correct ?    11 Yes 3 No

Question { Interra IT, 20909 }

How to rename all the files in a folder having specific
extension?
Example: I have some files with extension (.txt) in a folder
name 'Test'. I have to rename all the .txt files in a test
and its subdirectories to .my extension.


Answer

foreach x (`ls *.txt')
set y = `echo $x | cut -d . -f 1`
mv y y.my
done

Is This Answer Correct ?    1 Yes 0 No

Question { Cap Gemini, 23872 }

how to delete entire records in unix ?


Answer

use dd after place your curser on the record.

Is This Answer Correct ?    5 Yes 8 No