10 More Discussions You Might Find Interesting
1. Homework & Coursework Questions
First month learning about the Linux terminal and it has been a challenge yet fun so far. We're learning by using a gameshell. I'm trying to display a certain line ( only allowed 1 command ) from a file only using the head or tail. I'm pretty about this answer:
head -23 history.txt | tail -1... (1 Reply)
Discussion started by: forzatekk
1 Replies
2. UNIX for Beginners Questions & Answers
Hi Team,
Can anyone help me here:
I have to access server logs via putty and these logs file is a trailing file (continously updating) with ERROR and WARNINGS... I need to know if I can pull this trailing file to a local drive so that I can do some higlighting on some keywords through Notepad... (13 Replies)
Discussion started by: jitensetia
13 Replies
3. Shell Programming and Scripting
Hi,
I want to read a live log file line by line and considering those line which are newly added to file
Below code I am using, which read line but as soon as it read new line from log file its starts processing from very first line of file.
tail -F /logs/COMMON-ERROR.log | while read... (11 Replies)
Discussion started by: ketanraut
11 Replies
4. Shell Programming and Scripting
Hello Experts...
dir of FTP will list all the files in the directory. Is there any command or option of dir that will give me the most recent file only?
Since I couldn't find any such thing, I thought of creating a log file (of FTP results) and work on this log file to determine the most recent... (2 Replies)
Discussion started by: juzz4fun
2 Replies
5. Shell Programming and Scripting
Hi does anyone know how to create a file using the tail command? My book has this file I need to create and it says to use the tail command and that it is possible but I have no idea. Thanks. (4 Replies)
Discussion started by: drew211
4 Replies
6. UNIX for Dummies Questions & Answers
Please help with the following command
tail -f /appdata/logs/alert_audit517.txt | grep "Sep 02"
The problem I have is with the file name "alert_audit517.txt". The 3 digit number at the end of the file name changes, so I need the file name to use a wildcard. Ive tried alert_audit***.txt, but... (5 Replies)
Discussion started by: robertson1995
5 Replies
7. UNIX for Dummies Questions & Answers
Hi,
Here is my problem:
I try to write a script to find data in a file named "data" for exemple.
Let's say I am in the directory /x/y/z, there are several sub-directories in the "z" directory (each sub-directory has a file "data") and I am searching for the word "help".
So I use this... (9 Replies)
Discussion started by: StephB
9 Replies
8. UNIX for Advanced & Expert Users
How do you get your recent vi command history to show up? I keep randomly getting like my previous 5 commands and can't figure out how I'm doing it. I think it has something to do with the shift key and another button. (6 Replies)
Discussion started by: cokedude
6 Replies
9. Shell Programming and Scripting
Hi All,
My query seems to be silly but Iam unable to find where the exact problem lies.
I have a script to unzip set of files
here is the script
#!/bin/ksh
Count=`cat /home/gaddamja/Tempfile | wc -l`
while
do
Filename=`cat /home/gaddamja/Tempfile |tail -$Count | head -1`
cd... (7 Replies)
Discussion started by: jagadish_gaddam
7 Replies
10. Shell Programming and Scripting
I was wondering how can I do this
I have file myfile.txt
wc -l is: 5 000 000
I have to remove first 1 000 000 lines from header..
I tryed with tail -4000000 myfile.txt>newfile.txt
but it does not work...
any help?? (2 Replies)
Discussion started by: amon
2 Replies