QuestionMy Fedora repository is very big and a complete rebuild would take too long. How can I back up my repository so that I don't have to rebuild it? AnswerWhen performing a complete backup, several steps are involved:
This could be scripted as part of a regular backup process. Step 3 is not perfect, however: if you wait 5 minutes but someone is in the middle of upload a multi-GB file to the repository, you might still get an inconsistent backup. You could also watch the low level system activity (thread dump, strace, lsof, etc) to see if there are any ongoing writes. <?xml version="1.0" encoding="UTF-8"?> <Policy xmlns="urn:oasis:names:tc:xacml:1.0:policy" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" PolicyId="disable-writes" RuleCombiningAlgId="urn:oasis:names:tc:xacml:1.0:rule-combining-algorithm:first-applicable"> <Description>disable writes</Description> <Target> <Subjects> <AnySubject/> </Subjects> <Resources> <AnyResource/> </Resources> <Actions> <Action> <ActionMatch MatchId="urn:oasis:names:tc:xacml:1.0:function:string-equal"> <AttributeValue DataType="http://www.w3.org/2001/XMLSchema#string">urn:fedora:names:fedora:2.1:action:api-m</AttributeValue> <ActionAttributeDesignator DataType="http://www.w3.org/2001/XMLSchema#string" AttributeId="urn:fedora:names:fedora:2.1:action:api"/> </ActionMatch> </Action> </Actions> </Target> <Rule RuleId="1" Effect="Deny"/> </Policy> |