Strange folder on Solaris zone

Hi,
One of the file system is getting full and I was trying to do some housekeeping. I can see two logs directory, I am not sure how to fix it. if I go inside it, it goes inside smaller one

root@pdrpd01-ddp01:/# cd /ltd/apps/LOTM/TeamCDC34/TeamInvest
root@pdrpd01-ddp01:/ltd/apps/LOTM/TeamCDC34/TeamInvest# du -sk *
2020    logs
592183  logs -------> THIS ONE
root@pdrpd01-ddp01:/ltd/apps/LOTM/TeamCDC34/TeamInvest# cd logs
root@pdrpd01-ddp01:/ltd/apps/LOTM/TeamCDC34/TeamInvest# du -sk *
1       audit.log
0       collaborati.log
2018    system.log
0       xml.log
root@pdrpd01-ddp01:/ltd/apps/LOTM/TeamCDC34/TeamInvest#

Please run the following commands and show us the output:

cd /ltd/apps/LOTM/TeamCDC34/TeamInvest
du -sk * | od -bc
root@pdrpd01-ddp01:/ltd/apps/LOTM/TeamCDC34/TeamInvest# du -sk * | od -bc
0000000 062 060 062 060 011 154 157 147 163 012 065 071 062 061 070 063
           2   0   2   0  \t   l   o   g   s  \n   5   9   2   1   8   3
0000020 011 154 157 147 163 040 040 012
          \t   l   o   g   s          \n
0000030
root@pdrpd01-ddp01:/ltd/apps/LOTM/TeamCDC34/TeamInvest# 

So the 2nd directory name is logs (with two spaces after the "s"). Do you know how to deal with it now?

Wow... I am able to get in. How did you find it with that output ?

Simple: the characters between the <tab> ('\t' or octal 011) and the <newline> ('\n' or octal 012) are the file's name:

0000020 011 154 157 147 163 040 040 012
          \t   l   o   g   s          \n

If the characters had been anything other than a space, the text between "s" and "\n" would have indicated what control characters were present by a code indicating what was there rather than just spaces and the octal 040 confirms that they were <space> characters. (If you don't know the hex or octal codes for the characters, try man ascii .) When I saw your first post, I guessed that you had some combination of <space>, <tab>, <carriagereturn>, or <backspace> characters somewhere in the name; od -bc makes it easy to see what characters are hiding on the screen.

1 Like

Thanks for explaining it.