× NETGEAR will be terminating ReadyCLOUD service by July 1st, 2023. For more details click here.
Orbi WiFi 7 RBE973
Reply

How do i clean md0 ?

viperhansa
Virtuoso

How do i clean md0 ?

Hi guys..

 

Just in case my /dev/md0 is growing more, how can i clean it up?

/dev/md0 4.0G 1.1G 2.7G 28% 

 

I know there is no imminent danger but just wanna know.. 🙂

 

// Hans

Message 1 of 7

Accepted Solutions
mdgm-ntgr
NETGEAR Employee Retired

Re: How do i clean md0 ?

You could use the du command e.g.

 

# du -csh /var/log/*

 

28% full is pretty normal so I don't think you have anything to worry about.

View solution in original post

Message 4 of 7

All Replies
mdgm-ntgr
NETGEAR Employee Retired

Re: How do i clean md0 ?

First step is to find what's using up the space.

Message 2 of 7
viperhansa
Virtuoso

Re: How do i clean md0 ?

Yeah! that's one approach!  Smiley Tongue i like your sense of humor mdgm! 

 

Any tips how since i don't want to mess up anything?

 

Any step by step guide?

 

Regards

 

Hans

Message 3 of 7
mdgm-ntgr
NETGEAR Employee Retired

Re: How do i clean md0 ?

You could use the du command e.g.

 

# du -csh /var/log/*

 

28% full is pretty normal so I don't think you have anything to worry about.

Message 4 of 7
StephenB
Guru

Re: How do i clean md0 ?

If you don't have apps installed, then the main place to look is /var (and maybe /tmp)

 

If you do have apps installed (or have installed other packages yourself), then you need to know where they put their data, and consider moving it off the OS partition to the data volume somehow.  Sometimes that can be done through configuration, sometimes you can do it with soft links.

 

 

Message 5 of 7
viperhansa
Virtuoso

Re: How do i clean md0 ?


@mdgm wrote:

You could use the du command e.g.

 

# du -csh /var/log/*

 

28% full is pretty normal so I don't think you have anything to worry about.


 

 

That gave me:

4.0K    /var/log/alternatives.log
4.9M    /var/log/apache2
80K     /var/log/apt
8.0K    /var/log/btmp
292K    /var/log/ctscand.log
372K    /var/log/ctscand.log.old
304K    /var/log/dpkg.log
8.0K    /var/log/faillog
268K    /var/log/frontview
0       /var/log/fsck
32M     /var/log/journal
12K     /var/log/lastlog
4.0K    /var/log/LeafP2P.log
0       /var/log/mysql
0       /var/log/mysql.err
0       /var/log/mysql.log
0       /var/log/news
12K     /var/log/proftpd.log
1.3M    /var/log/readynasd
808K    /var/log/samba
300K    /var/log/wtmp
41M     total

What do i do with it?  🙂

Message 6 of 7
StephenB
Guru

Re: How do i clean md0 ?

If you had any run-away log files, you then truncate them (if you want to analyze them later, copy them to the data volume first).

echo > /var/log/logfilename.log

Message 7 of 7
Top Contributors
Discussion stats
  • 6 replies
  • 2448 views
  • 3 kudos
  • 3 in conversation
Announcements