Search Results

Search: Posts Made By: rahul2662
3,395
Posted By rahul2662
Hello agent.kgb, I tried the following...
Hello agent.kgb,

I tried the following commands but it didn't worked :-


$ ssh hostname sudo awk -F - -vDT=\"$(date -v-24H "+%b %_d %H:%M:%S")\" ' "DT<\$1 {print}" ' /var/log/messages
date:...
3,395
Posted By rahul2662
Run awk command on remote host
I have below command to check for error logs from last 24 hours from the file : /var/log/messages/ The command is working fine on the local host.


sudo awk -F - -vDT="$(date --date="24 hours ago"...
11,925
Posted By rahul2662
Hello RudiC, The following points also needs...
Hello RudiC,

The following points also needs to be satisfied by the script for a valid hostname naming convention :

1) The hostname cannot start or end with a hyphen.

In the below example...
11,925
Posted By rahul2662
Hello Ravinder, Below conditions should be...
Hello Ravinder,

Below conditions should be satisfied for a valid hostname :

1) Maximum 3 dots ( can have zero dots as well)
2) maximum 63 characters within each dot

for example below should...
11,925
Posted By rahul2662
Hello Ravinder, Thanks for your reply. :) I...
Hello Ravinder,

Thanks for your reply. :) I am actually developing a script to configure hostname. The script which will ask the user for the hostname. It will check for all the conditions...
11,925
Posted By rahul2662
Check for valid hostnames
Hello,

I am trying to develop a script to check for valid hostnames. Below are the prerequisites for a valid hostname which I got from wiki :

Hostnames are composed of series of labels...
1,398
Posted By rahul2662
Hello Ravinder , Yes there is only one...
Hello Ravinder ,

Yes there is only one occurence of "".

Also is there any simpler sed command to achieve this ?

Could you please explain following (RSTART and RLENGTH part) :...
1,398
Posted By rahul2662
Search for Pattern as output between the matched String
Hello,

I have a file which has the below contents :


VG_name LV_name LV_size in MB LV_option LV_mountpoint owner group y
testdg ...
3,864
Posted By rahul2662
Hello Ravinder , How can be have the <tr>...
Hello Ravinder ,

How can be have the <tr> and <td> tags around a space separated file. For example below is the file :

Ide Intir TID Grp Vendor Type Hypr Total Free...
3,864
Posted By rahul2662
Thanks a lot Ravinder , Also I need one...
Thanks a lot Ravinder ,

Also I need one small change in the Output.

In case of Drive bays and Summary Status of Contained Modules we need to have the following column : Value as well and output...
3,864
Posted By rahul2662
Loop to convert text output in the HTML format
Hello Everyone,

I have a sample file raw.txt as shown below :


Drive Bays

Bay Name : SD-2C
Number of Standby Power Supplies : 4
...
3,131
Posted By rahul2662
Hello agent.kgb, I am getting desired Output...
Hello agent.kgb,

I am getting desired Output on AIX 7.1. It seems that the ksh93 version is old on AIX5.3

Also Could you please help in converting epoch timestamp from the below file. The 7th...
3,131
Posted By rahul2662
Thanks a lot for your help and providing...
Thanks a lot for your help and providing excellent explaination :)

---------- Post updated 11-06-15 at 02:10 PM ---------- Previous update was 11-05-15 at 08:43 PM ----------

Hello,

The code...
3,131
Posted By rahul2662
Hello agent.kgb, Thanks a lot for your help....
Hello agent.kgb,

Thanks a lot for your help. It worked on Linux. I will test this on AIX as well. Does AIX 5.3 have ksh93 ?

Also can you please explain the command.

Thanks
Rahul
3,131
Posted By rahul2662
Hello agent.kgb, Your script is providing...
Hello agent.kgb,

Your script is providing effective timestamp in the below format where we are getting current timestamp :

EFFECTIVE_TIME Thu Nov 5 09:18:26 EST 2015

Although as per the...
3,131
Posted By rahul2662
Problem with While Loop in AIX Server
Hello,

I am trying to run the following Script on AIX Server. The script checks if first field is EFFECTIVE_TIME , if it is then it converts second field in readable format else it redirects...
9,179
Posted By rahul2662
Hello RudiC, The shell seems old. The...
Hello RudiC,

The shell seems old. The project is using AIX 5.3. Although I will test this command ASAP.

Thanks
Rahul
9,179
Posted By rahul2662
Hello Ravinder, The strftime function doesnt...
Hello Ravinder,

The strftime function doesnt works in AIX Server. I got the following error :

awk: 0602-553 Function strftime is not defined.

Thanks
Rahul
9,179
Posted By rahul2662
AIX : Need to convert UNIX Timestamp to normal timestamp
Hello ,

I am working on AIX. I have to convert Unix timestamp to normal timestamp. Below is the file. The Unix timestamp will always be preceded by
EFFECTIVE_TIME as first field as shown and...
2,442
Posted By rahul2662
Hello Ravinder, I have few questions here....
Hello Ravinder,

I have few questions here. Please help me.

1) In the below code does array B holds the value of complete line of Input_File (using $0) ? If yes then why we need index as $(NF-1)...
2,442
Posted By rahul2662
Hello RudiC, We are using RedHat Server....
Hello RudiC,

We are using RedHat Server. Please find below the Output from the server where we will be running the script :


~]$ date -d"10/11/2015 03:50:06PM"
Sun Oct 11 15:50:06 SGT 2015...
2,442
Posted By rahul2662
Sort Unique Column with the most recent timestamp
Hello,

I have a sample file with the below contents :


Backup Oracle8_P112_PEGA_Archivedel Completed full 10/11/2015 03:50:06PM
Backup Oracle8_G567_PEGA_Archivedel Completed ...
4,058
Posted By rahul2662
hello MadeinGermany, I also provided the...
hello MadeinGermany,

I also provided the directory and then only it worked :)

Thanks
Rahul
4,058
Posted By rahul2662
Hello Ravinder, Both the command didnt...
Hello Ravinder,

Both the command didnt returned any output.

Rahul

Apologies for the mistake. I got Output from the command. Thanks for the help
4,058
Posted By rahul2662
Find command not working on AIX
Hello,

I am running find command in an AIX Server to find last 7 days modified directories/files.


[root@hostname] >cd /usr/openv/netbackup/db/class
[root@hostname] >ls -l
total 0...
Showing results 1 to 25 of 66

 
All times are GMT -4. The time now is 01:45 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy