How would you truncate a log file that is growing too large
if you don't have space to compress it or to move it
somewhere else? How would you do it?

Answers were Sorted based on User's Feedback



How would you truncate a log file that is growing too large if you don't have space to compre..

Answer / bipin bapurao sautadekar

more two commands to truncate the file.

# cat /dev/null > filename
# cat > filename and then press ctrl+c

Is This Answer Correct ?    9 Yes 0 No

How would you truncate a log file that is growing too large if you don't have space to compre..

Answer / syed

Why not you try by using below command

> <file name>

Is This Answer Correct ?    10 Yes 2 No

How would you truncate a log file that is growing too large if you don't have space to compre..

Answer / chris lowder

cp /dev/null <File Name>

Is This Answer Correct ?    6 Yes 3 No

Post New Answer

More Solaris Commands Interview Questions

How will you check the process for particular user

2 Answers  


To find the OBP environment variable

2 Answers  


what is the diff between ufslog and vxfslog?

1 Answers  


How to configure domain controller in SAMBA using SOLARIS 10 OS and How to centralize domain name and creating users.How to share files for WINDOWS XP clients

1 Answers   IBM,


What is difference between g G while creating useradd?

1 Answers  






how to view how many samba user in solaris

4 Answers   3i Infotech,


How to enable and disable the dtlogin

1 Answers  


What are processing daemon in nis

2 Answers  


How to create a new volume

1 Answers  


IS THERE ANY WAY TO TAKE GOST BACKUP

1 Answers  


Have you done the patching, the patching is done by you only or some one will assign to you?

0 Answers   HP,


How to start llt and gab

1 Answers  


Categories
  • Solaris Commands Interview Questions Solaris Commands (360)
  • Solaris Threads Interview Questions Solaris Threads (9)
  • Solaris IPC Interview Questions Solaris IPC (30)
  • Solaris Socket Programming Interview Questions Solaris Socket Programming (3)
  • Solaris System Calls Interview Questions Solaris System Calls (25)
  • Solaris General Interview Questions Solaris General (170)
  • Solaris AllOther Interview Questions Solaris AllOther (297)