Sponsored Content
Full Discussion: Problem in file usage option
Top Forums Shell Programming and Scripting Problem in file usage option Post 302465267 by puni on Friday 22nd of October 2010 03:28:15 AM
Old 10-22-2010
Problem in file usage option

Hi,

I have a dout in -u option in ls command. If we give ls -lt command it will dispaly the last modfied time. If we give ls -lu command it will display the last usage time of the file.

My doubt here is Please refer the below commands.

Code:
/appldata/rsc/dm/RejectData$ls -lt ppi_amaz_dflt_disc_freq_dist_RejectData.bad
-rw-r-----   1 dqlet1   staff             0 Oct 15 13:11 ppi_amaz_dflt_disc_freq_dist_RejectData.bad
/appldata/rsc/dm/RejectData$ls -lu ppi_amaz_dflt_disc_freq_dist_RejectData.bad
-rw-r-----   1 dqlet1   staff             0 Sep 24 00:59 ppi_amaz_dflt_disc_freq_dist_RejectData.bad

In the above commnds in ls -lu command, i am getting the older date comparing with the timestamp in ls -lt command.

But ls -lu should show the newer timestamp right. Please correct me if i am wrong

Thanks,
Puni

Moderator's Comments:
Mod Comment You should be familiar using code tags instead of using different fonts etc. - I've sent a PM with a guide as reminder, thanks.

Last edited by zaxxon; 10-22-2010 at 04:40 AM..
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

problem in ssh with -i option

Hi All, I want to ssh to a remote terminal i did the following steps 1. On the client run the following commands: 2. $ mkdir -p $HOME/.ssh 3. $ chmod 0700 $HOME/.ssh 4. $ ssh-keygen -t dsa -f $HOME/.ssh/id_dsa -P '' and then tried the following $ ssh -i $HOME/.ssh/id_dsa server ... (1 Reply)
Discussion started by: gauri
1 Replies

2. UNIX for Dummies Questions & Answers

Usage of prstat -j option.

Hi, I need to capture output of prstat command for certain pid's .I found it as prstat -j filename. I created a filename projlist gave the pid number on the projlist file and run the cmd like this >prstat -j projlist prstat: illegal argument -- projlist can anybody suggest how to... (1 Reply)
Discussion started by: vipin771
1 Replies

3. HP-UX

how can I find cpu usage memory usage swap usage and logical volume usage

how can I find cpu usage memory usage swap usage and I want to know CPU usage above X% and contiue Y times and memory usage above X % and contiue Y times my final destination is monitor process logical volume usage above X % and number of Logical voluage above can I not to... (3 Replies)
Discussion started by: alert0919
3 Replies

4. Solaris

correct usage of find's -prune option

I know one of the more seasoned veterans probably opened this thread looking for their chance to refer me to the site's search feature and let me tell you. I'VE LOOKED!!!! And I didn't find anything helpful... So, I've got a windows background and I'm fond of its search feature which comes... (6 Replies)
Discussion started by: ProGrammar
6 Replies

5. AIX

How to monitor the IBM AIX server for I/O usage,memory usage,CPU usage,network..?

How to monitor the IBM AIX server for I/O usage, memory usage, CPU usage, network usage, storage usage? (3 Replies)
Discussion started by: laknar
3 Replies

6. UNIX for Advanced & Expert Users

Problem with useradd, -p option in Solaris 10

Good day all. I'm trying to add a user with useradd and the -p option to assign a project name, but the result is that the user is created with an error message: "UX: useradd: user.root name should be all lower case or numeric." The command: useradd -d /export/home/tester -g rtpgrp -G... (2 Replies)
Discussion started by: BRH
2 Replies

7. IP Networking

Problem when I Open my WireShark - No Interfaces Option available

Hi gurus of unix, I haved installed my openSolaris in a HP530, Recently I use the following command beadm destry opensolaris1 beadm destry opensolaris2 After That I reboot my Laptop. Well when I go to my work I try to open my wireshark tool, but the option in GUI interface does not appear!!!... (2 Replies)
Discussion started by: andresguillen
2 Replies

8. Shell Programming and Scripting

Problem with -c option in Mailx command

Hi, I am using mailx command in shell script. When i put -c option for CC , i get error message as "Unknown flag: -c" . I checked manual of mailx command and found that ~c to be used but after using ~c also it is not working. My shell is Korn. Kindly let me know what i have to do . Thanks (9 Replies)
Discussion started by: krishna_gnv
9 Replies

9. Shell Programming and Scripting

Problem in Using fgrep Command with pattern file option

Hi, i am using fgrep command with following syntax fgrep -v -f pattern_file_name file file contains few line and have the pattern which i am giving in pattern file. My Problem is : its is not giving any output. while i am using fgrep -f pattern_file_name file it is showing all... (4 Replies)
Discussion started by: emresearch
4 Replies

10. Shell Programming and Scripting

Problem with -s option in IF

Hello Guys , I am trying to run below in one of my script but unable to get it succeed . Can anyone help me on this? I am using HP-UX. if then write_log " Both files are present . Mail will be send to respective teams." EMAIL_SUBJECT="MGCA - File Extraction Process COMPLETED"... (12 Replies)
Discussion started by: himanshu sood
12 Replies
lugadmin(1M)															      lugadmin(1M)

NAME
lugadmin - long user and group name enablement and display SYNOPSIS
num] DESCRIPTION
The command enables the support of long user and group names on the system, sets the default display width for long user and group names, and displays the current status of the system. If no options are specified, the option is assumed. Options The following options are supported: Enable long user and group name support on the system. See the subsection below for details. This option requires superuser privileges. Set num as the default display width for long user and group names. num can be in the range to The option can be only be specified with the option or when long names have been previously enabled. See the subsection below for details. This option requires superuser privileges. Display the current status of the system. The command displays one of: The system is restricted to short (8-byte) user and group names. The system is enabled for long (255-byte) user and group name support. A name string can be up to 255 bytes plus a trailing NULL byte. Enabling Long User and Group Names To enable long user and group names, 1. Stop the daemon. 2. Run the command with the option. 3. The command requests confirmation before enabling the system. If you respond with or the command proceeds; otherwise, it aborts. 4. The command creates the file. 5. If the option is not specified, num defaults to The specified or default value of num is written in Setting the User and Group Name Display Width The long user and group name default display width is set when is executed with the option. It can be changed at any time by executing with the option. If is not specified with the option, the value of num defaults to Application Usage Use one of these: o in program code; see sysconf(2) and the section. o in program code; see ug_display_width(3C). o in shell scripts; see getconf(1) and the section. o in shell scripts and all return either (short names) or (long names). See ug_display_width(3C) for its return values. Use one of the following procedures: o In program code, call o In a shell script, 1. Run or to see if long names are enabled. If not enabled, set width to 2. Else, if enabled, check for the environment variable. If the variable is set to a value between set width to the value. Oth- erwise set width to 3. Else, if not set, set width to the value in the file. Set width to if the value is out of range, not an integer, or improperly formatted. The current display width is used by all system and conforming applications to display formatted output. See section of ug_dis- play_width(3C) for usage of current display width. EXTERNAL INFLUENCES
Environment Variables If it is set and long names are enabled, it overrides the width specified in the file for all system and conforming applications that write formatted output. RETURN VALUE
exits with one of the following values: Successful completion Failure DIAGNOSTICS
You may have attempted to use the option for a second time. You tried to use the option before using the option. A call to the function failed. WARNINGS
The file is the switch that marks a long name system. If it is missing, short names are assumed and the variable is ignored. While many programs are unaffected by long names in a short name environment, some may behave abnormally and some may abort. It is recommended that you do not attempt to restore the short name environment once long names have been enabled. Do not use the system constant with the command or the function to test for name length; it is not changed when long names are enabled. AUTHOR
was developed by HP. FILES
If this file is present, the system is enabled for long user and group names; otherwise, it is not. This file contains the default display width, as set with the option. SEE ALSO
getconf(1), sysconf(2), ug_display_width(3C) lugadmin(1M)
All times are GMT -4. The time now is 05:53 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy