class2_22i272
class2_22i272
LAB REPORT-2
EXERCISE - 2 VIMALATHITHAN D
07.02.2024 22I272
AIM:
To implement the UNIX commands.
COMMANDS:
1. uptime Command:
2. reboot Command:
3. date Command:
You can set the system date and time using the -s option followed by the desired date
and time.
10. lslogins:
To display the current time in Unix timestamp format (number of seconds since January
1, 1970, 00:00:00 UTC).
13. Display Date and Time with Timezone Offset:
To display the current date and time along with the timezone offset.
To display the current date and time in ISO 8601 format with timezone information.
To display the current date and time in RFC 3339 format (ISO 8601 extended format).
To display the current date and time in seconds since the epoch (January 1, 1970).
23. Display date and time in a Custom Format:
You can create custom date and time formats using various format specifiers.
To display the current date and time in Coordinated Universal Time (UTC).
To display the current date and time with seconds and nanoseconds.
28. Display day of the year:
To display the day of the year (1-365 or 1-366 for leap years).
To display the week number with the week starting on Sunday or Monday.
To display the date and time in a custom format with a specific timezone.
33. Display date and time in RFC 2822 format with Timezone:
To display the date and time in RFC 2822 format with timezone.
35. w Command:
This command tells about the users who are logged in and what are they doing.
39. id Command:
This command basically prints the information of real and effective user or in other
words the current user.
Open a file using the default application associated with its MIME type.
The best use case of tail in my opinion is when called with the -f option. It opens the file at
the end, and watches for file changes. Any time there is new content in the file, it is printed
in the window.
48. who Comment:
Type whoami to print the user name currently logged in to the terminal session.
The Linux which command is used to locate the executable files or location of a program
from the file system.