Hi,
I understand that the ls command with "-l" option generates the "last modified time" of specific directory.
However, some generated results displayed the "last modified time" with detail about the last modified year, for example:
-rwxrwxrwx+ 1 smith dev 10876 May 16 2005 part2
... (6 Replies)
Hi all ..
As per rule i searched the forum i am not able found out ...
I want to display the year in when listing the files .. when i use ls -lt it is not displaying files with recent 6 month old ..
I know that perderabo has written a script for that if you give that link it will be... (3 Replies)
Hi,
When retrieving parameters of a file using ls command i need to print the year part . When i do ls -ltr the following output is displayed
-rwxrwxrwx 1 d_infd d_infd 1711 Jan 8 2004 wf1.class.
Here the year part is not displayed only Jan 8 is displayed.
Can any one... (9 Replies)
Hi All,
i want the last login details along with year.
i tried below command but not giving me the year of last login.
last <$Userid> | head -1
i heard that if it is current year then it wont display the year else it will display the year. is it so?
if yes then , is there any way of... (1 Reply)
Hi All,
i want the last login details along with year.
i tried below command but not giving me the year of last login.
last <$Userid> | head -1
i heard that if it is current year then it wont display the year else it will display the year. is it so?
if yes then , is there any way of... (1 Reply)
What is the uptime command output when the server is running more than one year?
My doubt is whether it show in number of days format or number years and number of days format?
For example, Assume the server is running 400 days 3 hrs 3 min 3 secs. The output like 400 days 3:3 min or 1 year 5... (3 Replies)
Hi all,
Need an urgent help on the below scenario.
script:
awk -F","
'BEGIN { #some variable assignment}
{ #some calculation and put values in array}
END {
year=#getting it from array and assume this will be 2014
month=#getting it from array and this will be 05
date=#... (7 Replies)
hi all,
I use
date +%Y
which gives Current year.
Requirement: I want previous year to be printed. Please help me.
Note: I tried
date +%d/%m/%Y -d "-1 years" which is not working. (10 Replies)
Hi All,
Have a file where i stored ls -l command output,
-rw-r--r-- 1 360 600 94255 Jan 01 11:16 file1_2020.csv
-rw-r--r-- 1 360 600 114573 Dec 29 11:10 file2_2019.csv
-rw-r--r-- 1 360 600 41006 Dec 30 11:09 file3_2019.csv
-rw-r--r-- 1 360 ... (9 Replies)
Discussion started by: kumarinfa
9 Replies
LEARN ABOUT HPUX
lastb
last(1) General Commands Manual last(1)NAME
last, lastb - indicate last logins of users and ttys
SYNOPSIS
file] [name ...] [tty ...]
file] [name ...] [tty ...]
DESCRIPTION
The command searches backwards through the file (which contains a record of all logins and logouts) for information about a user, a tty, or
any group of users and ttys. Arguments specify names of users or ttys of interest. The names of ttys can be given fully or abbreviated.
For example, is the same as If multiple arguments are given, the information that applies to any of the arguments is printed. For example,
lists all of sessions as well as all sessions on the console terminal. The command prints the sessions of the specified users and ttys,
most recent first, indicating when the session began, the duration of the session, and the tty on which the session took place. indicates
if the session is still in progress or if it was cut short by a reboot.
The pseudo-user logs each time the system reboots. Thus, is a useful command for evaluating the relative time between system reboots.
If is interrupted, it indicates how far the search has progressed in If interrupted by a quit signal (generated by a Ctrl-), indicates how
far the search has progressed, then continues the search.
The command searches backwards through the database file to display bad login information. Access to should be restricted to users with
appropriate privileges (owned by and readable only by because it may contain password information.
Options
The and commands recognize the following options and arguments:
(none) If no arguments are specified, prints a record of all logins and logouts in reverse order, most recent first.
When used with
and displays the user's host name as it is stored in the files and respectively. The host name is displayed between the
tty name and the user's login time.
Limits the report to
number of lines.
Use file as the name of the accounting file instead of or
Use file as the name of the accounting database instead of This option should be used along with the option.
Display the fields in long format if this flag is used
along with the flag. Without the flag, normal output is displayed.
AUTHOR
was developed by the University of California, Berkeley and HP.
FILES
Bad login database
Login database
New login database
New bad login database
SEE ALSO login(1), utmp(4), wtmps(4).
last(1)