[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [tor-bugs] #30880 [Internal Services/Tor Sysadmin Team]: document backup/restore procedures



#30880: document backup/restore procedures
-------------------------------------------------+-------------------------
 Reporter:  anarcat                              |          Owner:  anarcat
     Type:  task                                 |         Status:
                                                 |  accepted
 Priority:  Medium                               |      Milestone:
Component:  Internal Services/Tor Sysadmin Team  |        Version:
 Severity:  Normal                               |     Resolution:
 Keywords:                                       |  Actual Points:
Parent ID:                                       |         Points:
 Reviewer:                                       |        Sponsor:
-------------------------------------------------+-------------------------

Comment (by anarcat):

 This SQL query will create a series of commands that can be fed into
 bconsole to "purge" old volumes:

 {{{
 SELECT 'prune yes volume=' || volumename FROM media WHERE lastwritten <
 NOW() - INTERVAL '30 days' AND poolid IN (SELECT poolid FROM pool WHERE
 name LIKE '%arlgirdense.torproject.org') ORDER BY lastwritten;
 }}}

 Yet this lists volumes that are already pruned, so I'm not sure it's the
 right thing. Maybe we should use `delete` instead of `prune`? In this,
 according to Langille's blog, we'd also need `AND voljobs=0` to avoid
 deleting volumes with jobs referencing it.

 Our database is pretty big:

 {{{
 /dev/vdc           197G    131G   57G  70% /var/lib/postgresql
 }}}

 ... so it might actually be worth removing old cruft. But our priority
 should be to remove the actual *files* from older backups, and maybe
 that's as simple as removing them by hand from the storage daemon.

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/30880#comment:3>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs