FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » FUDforum » How To » Automated backups
Show: Today's Messages :: Polls :: Message Navigator
Switch to threaded view of this topic Create a new topic Submit Reply
Automated backups [message #28485] Wed, 26 October 2005 12:26 Go to next message
BugLaden is currently offline  BugLaden   United States
Messages: 216
Registered: February 2002
Location: Westminster, MD
Karma: 0
Senior Member
Is the syntax on in the manual for automated backups correct?

Here is the command in Cron;

echo -e 'submitted=1\n&compress=1\n&path=/usr/fudforum/backup/fud_'`date +\%Y\%m\%d`'.gz' | 
lynx http://www.ccgworkshop.com/forum/adm/admdump.php?do_http_auth=1 -auth=<username>:<pass> -post_data


This is the output from the Cron job:

   [1]Return To Forum
   Admin Control Panel
   Checks/Consistency
   [2]Forum Consistency
   [3]Rebuild Search Index
   [4]Compact Messages
   General Management
   [5]Global Settings Manager
   [6]Replacement & Censorship System
   [7]MIME Managment System
   [8]RDF Feed Managment
   [9]PDF Generation Managment
   [10]File Manager
   [11]Lock/Unlock Forum's Files
   [12]Forum Statistics
   [13]Action Log Viewer
   [14]Error Log Viewer
   [15]System Info
   Forum Management
   [16]Category & Forum Management
   [17]Deleted Forums
   [18]Announcement Manager
   [19]Topic Pruning
   [20]Attachment Pruning
   [21]Mailing List Manager
   [22]Newsgroup Manager
   User Management
   [23]Moderator/User Manager
   [24]Add User
   [25]Account Approval
   [26]Groups Manager
   [27]Mass Email
   [28]Rank Manager
   [29]Privileged User List
   [30]Banned User List
   Template Management
   [31]Theme Manager
   [32]Template Editor
   [33]Message Editor
   Icon Management
   [34]Smiley Manager
   [35]Forum Icon Manager
   [36]Message Icon Manager
   Avatar Management
   [37]Avatar Approval
   [38]Avatar Manager
   Filters
   [39]Email filter
   [40]IP filter
   [41]Login filter
   [42]File filter
   Forum Data Management
   [43]Make forum datadump
   [44]Import forum data

FUDforum Backup

   _hs
   Backup Save Path
   path on the disk, where you wish the forum data dump to be saved.
   Couldn't open backup destination file,
   /usr/fudforum/backup/fud_20051026.gz for write.
   ________________________________________
   Use Gzip Compression
   if you choose this option, the backup files will be compressed using
   Gzip compression. This may make the backup process a little slower,
   but will save a lot of harddrive space. [_] Yes
   Make Backup

References

   1. http://www.ccgworkshop.com/forum/__fud_index_name__?__adm_rsidl
   2. http://www.ccgworkshop.com/forum/adm/consist.php?__adm_rsidl
   3. http://www.ccgworkshop.com/forum/adm/indexdb.php?__adm_rsidl
   4. http://www.ccgworkshop.com/forum/adm/compact.php?__adm_rsidl
   5. http://www.ccgworkshop.com/forum/adm/admglobal.php?__adm_rsidl
   6. http://www.ccgworkshop.com/forum/adm/admreplace.php?__adm_rsidl
   7. http://www.ccgworkshop.com/forum/adm/admmime.php?__adm_rsidl
   8. http://www.ccgworkshop.com/forum/adm/admrdf.php?__adm_rsidl
   9. http://www.ccgworkshop.com/forum/adm/admpdf.php?__adm_rsidl
  10. http://www.ccgworkshop.com/forum/adm/admbrowse.php?__adm_rsidl
  11. http://www.ccgworkshop.com/forum/adm/admlock.php?__adm_rsidl
  12. http://www.ccgworkshop.com/forum/adm/admstats.php?__adm_rsidl
  13. http://www.ccgworkshop.com/forum/adm/admlog.php?__adm_rsidl
  14. http://www.ccgworkshop.com/forum/adm/admerr.php?__adm_rsidl
  15. http://www.ccgworkshop.com/forum/adm/admsysinfo.php?__adm_rsidl
  16. http://www.ccgworkshop.com/forum/adm/admcat.php?__adm_rsidl
  17. http://www.ccgworkshop.com/forum/adm/admdelfrm.php?__adm_rsidl
  18. http://www.ccgworkshop.com/forum/adm/admannounce.php?__adm_rsidl
  19. http://www.ccgworkshop.com/forum/adm/admprune.php?__adm_rsidl
  20. http://www.ccgworkshop.com/forum/adm/admaprune.php?__adm_rsidl
  21. http://www.ccgworkshop.com/forum/adm/admmlist.php?__adm_rsidl
  22. http://www.ccgworkshop.com/forum/adm/admnntp.php?__adm_rsidl
  23. http://www.ccgworkshop.com/forum/adm/admuser.php?__adm_rsidl
  24. http://www.ccgworkshop.com/forum/adm/admadduser.php?__adm_rsidl
  25. http://www.ccgworkshop.com/forum/adm/admaccapr.php?__adm_rsidl
  26. http://www.ccgworkshop.com/forum/adm/admgroups.php?__adm_rsidl
  27. http://www.ccgworkshop.com/forum/adm/admmassemail.php?__adm_rsidl
  28. http://www.ccgworkshop.com/forum/adm/admlevel.php?__adm_rsidl
  29. http://www.ccgworkshop.com/forum/adm/admslist.php?__adm_rsidl
  30. http://www.ccgworkshop.com/forum/adm/admbanlist.php?__adm_rsidl
  31. http://www.ccgworkshop.com/forum/adm/admthemes.php?__adm_rsidl
  32. http://www.ccgworkshop.com/forum/adm/tmpllist.php?__adm_rsidl
  33. http://www.ccgworkshop.com/forum/adm/msglist.php?__adm_rsidl
  34. http://www.ccgworkshop.com/forum/adm/admsmiley.php?__adm_rsidl
  35. http://www.ccgworkshop.com/forum/adm/admforumicons.php?__adm_rsidl
  36. http://www.ccgworkshop.com/forum/adm/admforumicons.php?__adm_rsidl&which_dir=1
  37. http://www.ccgworkshop.com/forum/adm/admapprove_avatar.php?__adm_rsidl
  38. http://www.ccgworkshop.com/forum/adm/admavatar.php?__adm_rsidl
  39. http://www.ccgworkshop.com/forum/adm/admemail.php?__adm_rsidl
  40. http://www.ccgworkshop.com/forum/adm/admipfilter.php?__adm_rsidl
  41. http://www.ccgworkshop.com/forum/adm/admlogin.php?__adm_rsidl
  42. http://www.ccgworkshop.com/forum/adm/admext.php?__adm_rsidl
  43. http://www.ccgworkshop.com/forum/adm/admdump.php?__adm_rsidl
  44. http://www.ccgworkshop.com/forum/adm/admimport.php?__adm_rsidl



-=BugLaden

[Updated on: Wed, 26 October 2005 14:08]

Report message to a moderator

Re: Automated backups [message #28487 is a reply to message #28485] Wed, 26 October 2005 13:41 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
To use it on a command line you need to edit the script and uncomment the lines documented with in-code comments to make it usable as a command line app.

FUDforum Core Developer
Re: Automated backups [message #28489 is a reply to message #28485] Wed, 26 October 2005 14:07 Go to previous messageGo to next message
BugLaden is currently offline  BugLaden   United States
Messages: 216
Registered: February 2002
Location: Westminster, MD
Karma: 0
Senior Member
After I posted the last message I did a search on cron on this forum and found that as well.

I edited admdump.php so the pertinant section looks like this

	// uncomment the lines below if you wish to run this script via command line
	fud_use('adm_cli.inc', 1); // this contains cli_execute() function.
	// when using this the script accepts 2 arguments
	// php admdump.php /path/to/dump_file [compress]
	// compress is optional and should only be specified if you want to datadump to be compressed

	/* check for cli arguments */
	if (defined('forum_debug')) {
		if (empty($_SERVER['argv'][1])) {
			exit("Usage: php admdump.php /path/to/dump_file [compress]\n");
		}
		$_POST['submitted'] = 1;
		$_POST['path'] = $_SERVER['argv'][1];
		if (!empty($_SERVER['argv'][2])) {
			$_POST['compress'] = 1;
		}
	}



however when I run it from the command line here is the output:

php admdump.php
Status: 302
Content-type: text/html
X-Powered-By: PHP/4.3.4
P3P: CP="ALL CUR OUR IND UNI ONL INT CNT STA"
Set-Cookie: fud_session_1130263541=e49b4bb0261edc194505c6aa942a4393; expires=Wed, 02-Nov-05 13:39:58 GMT; path=/forum/; domain=.ccgworkshop.com
Location: http://www.ccgworkshop.com/forum/adm/admloginuser.php?S=e49b4bb0261edc194505c6aa942a4393


Due to the lack of parameters it should have kicked back and error message. So what am I missing?


-=BugLaden
Re: Automated backups [message #28490 is a reply to message #28489] Wed, 26 October 2005 14:28 Go to previous message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
Put cli_execute(''); after the fud_use('adm_cli.inc', 1); line.

FUDforum Core Developer
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Group permissions again
Next Topic: Posts sent to more than one mailing list
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Thu Oct 31 23:20:33 GMT 2024

Total time taken to generate the page: 0.06153 seconds