Ken Roy Posted January 17, 2009 Report Share Posted January 17, 2009 Alright, glad to hear the good news. Here's the file with the corrected "Resore" fixed. =)Ben,Thanks for updating the mod and installing it in the admin directory. I have updated the TNG Wiki Backup / Restore Living Flag to point to the latest download, and the Admin Header Mod to update the Backup Living anchor to point to the new script name and location. Quote Link to comment Share on other sites More sharing options...
thewag Posted January 18, 2009 Author Report Share Posted January 18, 2009 Ben,Thanks for updating the mod and installing it in the admin directory. I have updated the TNG Wiki Backup / Restore Living Flag to point to the latest download, and the Admin Header Mod to update the Backup Living anchor to point to the new script name and location.Excellent! You just made my life just a little bit easier. Much appreciated. Quote Link to comment Share on other sites More sharing options...
jgrantham Posted February 19, 2009 Report Share Posted February 19, 2009 I get this error when I click on the new link:Fatal error: Call to undefined function: tng_adminheader() in /home/kb5wck/www/genealogy/admin/backupLiving.php on line 50Am i missing something?Excellent! You just made my life just a little bit easier. Much appreciated. Quote Link to comment Share on other sites More sharing options...
kazooter Posted December 27, 2009 Report Share Posted December 27, 2009 I followed the wiki instructions, downloaded and installed the backupLiving files with mod manager. It installed with no problems, but when I used it the first time I got the following:Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 9913080 bytes) in W:\www\admin\backupLiving.php on line 351. Line 351 tries to include_once ($backupfile).Perhaps I need to increase allocated memory somewhere?Any suggestions? Quote Link to comment Share on other sites More sharing options...
thewag Posted December 27, 2009 Author Report Share Posted December 27, 2009 Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 9913080 bytes) in W:\www\admin\backupLiving.php on line 351. Take a look at the backfupfile. Is it there? Does it appear correct (no odd characters for example)? What is its size? What are its read/write permissions? Quote Link to comment Share on other sites More sharing options...
kazooter Posted December 28, 2009 Report Share Posted December 28, 2009 Take a look at the backfupfile. Is it there? Does it appear correct (no odd characters for example)? What is its size? What are its read/write permissions?Yes, the backupfile (living_data.backup.php) looks normal. It is 2.9 GB and there are 82,609 lines of data in it. It quit at after record 13768, which is about half way through my database, and it added the php closing tag at the end. It looks like the file may have gotten too big and I've exceeded some sort of server limit. Have you tested it on files this large? I am running the script on my desktop localhost installation (Uniform Server). I will dig into the server config tomorrow to see if I can find a problem. Looking at it again, I'm wondering if the $living[] array in this file is just too large for the available memory...... Quote Link to comment Share on other sites More sharing options...
Scotty Posted December 28, 2009 Report Share Posted December 28, 2009 Yes, the backupfile (living_data.backup.php) looks normal. It is 2.9 GB and there are 82,609 lines of data in it. It quit at after record 13768, which is about half way through my database, and it added the php closing tag at the end. It looks like the file may have gotten too big and I've exceeded some sort of server limit. Have you tested it on files this large? I am running the script on my desktop localhost installation (Uniform Server). I will dig into the server config tomorrow to see if I can find a problem. Looking at it again, I'm wondering if the $living[] array in this file is just too large for the available memory......Find php.ini, it's under usr/local/php, and load that file into your favorite text editor and search for "memory_limit" and increase the 32M to 200M and see what happens.It will probably work now.... Scotty Quote Link to comment Share on other sites More sharing options...
thewag Posted December 28, 2009 Author Report Share Posted December 28, 2009 Yes, the backupfile (living_data.backup.php) looks normal. It is 2.9 GB and there are 82,609 lines of data in it. It quit at after record 13768, which is about half way through my database, and it added the php closing tag at the end. It looks like the file may have gotten too big and I've exceeded some sort of server limit. Have you tested it on files this large? I am running the script on my desktop localhost installation (Uniform Server). I will dig into the server config tomorrow to see if I can find a problem. Looking at it again, I'm wondering if the $living[] array in this file is just too large for the available memory......WOW! That is a huge backup file. Mine's only 300k with 8449 lines. Oddly though, that doesn't scale to your 2.9GB. I know other people use it with larger databases, but I don't know how large. Generally if the script "fails" to finish writing, then there is not closing "?>" tag.Things to check:According to the TNG stats, how many living people are in your database?Does that match the 13768 (assuming that is the ID in the $living array)?I would expect an 80,000 line backup file to have a size of 3M, not 3G. I would go with Scotty's suggestion below first, but something seems odd about the size to record ratio.Find php.ini, it's under usr/local/php, and load that file into your favorite text editor and search for "memory_limit" and increase the 32M to 200M and see what happens. Quote Link to comment Share on other sites More sharing options...
kazooter Posted December 28, 2009 Report Share Posted December 28, 2009 WOW! That is a huge backup file. Mine's only 300k with 8449 lines. Oddly though, that doesn't scale to your 2.9GB. I know other people use it with larger databases, but I don't know how large. Generally if the script "fails" to finish writing, then there is not closing "?>" tag.Things to check:According to the TNG stats, how many living people are in your database?Does that match the 13768 (assuming that is the ID in the $living array)?I would expect an 80,000 line backup file to have a size of 3M, not 3G. I would go with Scotty's suggestion below first, but something seems odd about the size to record ratio.My bad. Comes from working too late. The actual file size is 2.9MB. The closing tag tells me the file was created without error. The error came when it was 'included' in the script. Probably just a server setting needs to be changed.I have around 25k total records, many erroneously marked living. I am in the process of correcting them and want to use your script when I get them right to keep them right. Thanks for the script and the feedback.Find php.ini, it's under usr/local/php, and load that file into your favorite text editor and search for "memory_limit" and increase the 32M to 200M and see what happens.It will probably work now.... ScottyThanks for the time-saving tip, Scotty. I try it later this afternoon and let you know. Quote Link to comment Share on other sites More sharing options...
thewag Posted December 28, 2009 Author Report Share Posted December 28, 2009 My bad. Comes from working too late. The actual file size is 2.9MB. The closing tag tells me the file was created without error. The error came when it was 'included' in the script. Probably just a server setting needs to be changed.Whew! Glad to know that. I work with files of several Gigs at work, not with TNG. I've been puzzling what would have caused such an increase. Hope the mem increase helps. Let us know.Ben Quote Link to comment Share on other sites More sharing options...
kazooter Posted December 28, 2009 Report Share Posted December 28, 2009 Find php.ini, it's under usr/local/php, and load that file into your favorite text editor and search for "memory_limit" and increase the 32M to 200M and see what happens.It will probably work now.... ScottyJust edited the php.ini file as you suggested and everything worked. Thanks!Whew! Glad to know that. I work with files of several Gigs at work, not with TNG. I've been puzzling what would have caused such an increase. Hope the mem increase helps. Let us know.BenScotty's php.ini suggestion fixed the problem. Everything normal. Thanks again for the script. Quote Link to comment Share on other sites More sharing options...
Scotty Posted December 28, 2009 Report Share Posted December 28, 2009 You might want to play with that setting and see where your database breaks. Because if you ever go to a real hosting company they may not allocate enough memory on shared hosting accounts. And they may not allow you to change that number. That setting also affects the thumbnail creation mechanism of TNG. GDlib requires a lot of temporary memory as you increase the resolution of an image file. A 3 meg image file would require +-30 meg of memory for the conversion.Just some things to consider when selecting a hosting company. Quote Link to comment Share on other sites More sharing options...
David Mantione Posted January 18, 2010 Report Share Posted January 18, 2010 I used the Mod Manager configuration script and the "backupLiving.php" document. Mod Manager installed it but when I went to run "Back Up Living" from either the left side or the Admin "Back Up Living" button, I get the following error:Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /homepages/23/d260503398/htdocs/admin/backupLiving.php on line 8Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /homepages/23/d260503398/htdocs/admin/backupLiving.php on line 11Parse error: syntax error, unexpected T_VARIABLE in /homepages/23/d260503398/htdocs/admin/backupLiving.php on line 12Can anyone help on this?Thanks David from NYCMantione Family History Quote Link to comment Share on other sites More sharing options...
bsl20b50 Posted January 30, 2010 Report Share Posted January 30, 2010 Find php.ini, it's under usr/local/php, and load that file into your favorite text editor and search for "memory_limit" and increase the 32M to 200M and see what happens.It will probably work now.... ScottyI just increased my database size significantly and now I'm having this same issue (the mod was working fine before). I tried to find my php.ini file and can't find it.Any ideas so I can get this straightened out?Bryan Quote Link to comment Share on other sites More sharing options...
thewag Posted January 30, 2010 Author Report Share Posted January 30, 2010 I just increased my database size significantly and now I'm having this same issue (the mod was working fine before). I tried to find my php.ini file and can't find it.Any ideas so I can get this straightened out?BryanHey Bryan, it varies on OS and distribution and server package. Please give details. Quote Link to comment Share on other sites More sharing options...
theKiwi Posted January 30, 2010 Report Share Posted January 30, 2010 I just increased my database size significantly and now I'm having this same issue (the mod was working fine before). I tried to find my php.ini file and can't find it.If you go into the TNG Admin ------> Setup ------> Diagnostics screen and get the PHP Info Screen, that will tell you the path to the php.ini file in there - it's the 6th item down on my server.Roger Quote Link to comment Share on other sites More sharing options...
thewag Posted January 30, 2010 Author Report Share Posted January 30, 2010 If you go into the TNG Admin ------> Setup ------> Diagnostics screen and get the PHP Info Screen, that will tell you the path to the php.ini file in there - it's the 6th item down on my server.RogerOr that...Leave it to me to try something harder! Quote Link to comment Share on other sites More sharing options...
bsl20b50 Posted January 30, 2010 Report Share Posted January 30, 2010 If you go into the TNG Admin ------> Setup ------> Diagnostics screen and get the PHP Info Screen, that will tell you the path to the php.ini file in there - it's the 6th item down on my server.RogerOK, so I found my path: /usr/local/etc/php5/cgiPerhaps I am showing my lack of knowledge, but I can't seem to get to that path. Do I use a browser, an FTP client, cPanel? I have tried all 3 and can't seem to find my way there. Do I download the php.ini file using FTP or some other way.Thanks,Bryan Quote Link to comment Share on other sites More sharing options...
thewag Posted January 30, 2010 Author Report Share Posted January 30, 2010 OK, so I found my path: /usr/local/etc/php5/cgiPerhaps I am showing my lack of knowledge, but I can't seem to get to that path. Do I use a browser, an FTP client, cPanel? I have tried all 3 and can't seem to find my way there. Do I download the php.ini file using FTP or some other way.Thanks,BryanSounds like you're one a hosting provider. If that's the case, then you won't be able to edit that php.ini file. You're SP may allow some overriding, but that will depend specifically on the SP. Quote Link to comment Share on other sites More sharing options...
bsl20b50 Posted February 1, 2010 Report Share Posted February 1, 2010 Sounds like you're one a hosting provider. If that's the case, then you won't be able to edit that php.ini file. You're SP may allow some overriding, but that will depend specifically on the SP.With that said, would the best approach be to contact my host (Lunarpages)?If they will not allow an override, what should my next step be?Thanks,Bryan Quote Link to comment Share on other sites More sharing options...
thewag Posted February 1, 2010 Author Report Share Posted February 1, 2010 With that said, would the best approach be to contact my host (Lunarpages)?If they will not allow an override, what should my next step be?Thanks,BryanA quick google of "php ini override" gives How to override php.ini as at least one method. I'd look the the SP's FAQ and such first, try a few alternatives, and if nothing works, then contact them. I would guess that SP's may be hesitant to allow overrides, especially of settings that could impact other users of the server. Guess I'm suggesting a "Better to ask forgiveness then permission" scenario.I don't use a SP, so hopefully others will chime in.Ben Quote Link to comment Share on other sites More sharing options...
Ken Roy Posted February 1, 2010 Report Share Posted February 1, 2010 With that said, would the best approach be to contact my host (Lunarpages)?If they will not allow an override, what should my next step be?Thanks,BryanBryan,Looking at the support forums on Lunarpages, they appear to allow php overrides. The location of the php.ini file may not be accessible to you, since I believe that is the server's php.ini file. On ICDSoft, mine shows as Configuration File (php.ini) Path .:/etc but then the Loaded Configuration File shows my account rootpath.So you should be able to place your php.ini override in your account rootpath on Lunarpages. Quote Link to comment Share on other sites More sharing options...
bsl20b50 Posted February 1, 2010 Report Share Posted February 1, 2010 Bryan,Looking at the support forums on Lunarpages, they appear to allow php overrides. The location of the php.ini file may not be accessible to you, since I believe that is the server's php.ini file. On ICDSoft, mine shows as Configuration File (php.ini) Path .:/etc but then the Loaded Configuration File shows my account rootpath.So you should be able to place your php.ini override in your account rootpath on Lunarpages.Ken,Thanks! that did it!I created a php.ini file with following text:upload_max_filesize = 50Mpost_max_size = 50M Then I updated my .htaccess file with the following line of code:suPHP_ConfigPath /home/USERNAMEHERE/public_htmlNot knowing what the original php.ini file looked like makes me a little nervous. Is it possible that I omitted something important? Could my override cause any problems?Thanks again,Bryan Quote Link to comment Share on other sites More sharing options...
Ken Roy Posted February 1, 2010 Report Share Posted February 1, 2010 Ken,Thanks! that did it!I created a php.ini file with following text:upload_max_filesize = 50Mpost_max_size = 50M Then I updated my .htaccess file with the following line of code:suPHP_ConfigPath /home/USERNAMEHERE/public_htmlNot knowing what the original php.ini file looked like makes me a little nervous. Is it possible that I omitted something important? Could my override cause any problems?Thanks again,BryanBryan,As indicated in the TNG Wiki article on PHP Overrides, You will need to check with your hosting service as to what other parameters you may need to include for compatibility reasons. Quote Link to comment Share on other sites More sharing options...
puppydog Posted March 27, 2010 Report Share Posted March 27, 2010 Alright, I got tired of changing things in my local software, uploading the gedcom, and then having to set the living flags....again! So I created this script that will backup and restore living flags.Small cavets (sp?):personID numbers can't changegedcom names can't changeit is still in rough form.This is still very rough, but it works!! The only item it touches is to add the living flag to people you select on restore. I doesn't change anybody elses flags. Only the ones you select. It won't remove living flags.Hope someone else finds this usefull.BenallThis is my first attempt to install a TNG Mod so please bear with me if I'm doing something stupid (happens sometimes ). I installed Mod Manager and ran it for the first time. Seemed to have worked fine except for two things: (1) it shows up in the rightmost column on the Admin Home page with the left column blank (I'm referring to the main window, not the left sidebar), aqnd (2) when I login as a non-admin user, the Administration link shows in the left sidebar of the Home Page, but not in the Info drop-down menu. These are not my immediate concern. I mention them only if they might have a bearing on my problem installing the Backup Living Flag mod. Just prior to installing Mod Manager, I updated TNG from v7.1.2 to v7.1.3 using the update zip file. Everything seems to have worked fine, except as noted above. Oh yes, I'm running WAMP under XP. Haven't uploaded to my live domain yet.Now to my real problem. I unzipped the Living_flag_backup_v2.1 download (from Wiki). The only file in it was living_flag_backup_v2.1.cfg which I copied to tng/admin/mod_folder. When I run Mod Manager I get a Cleanup message: ADMIN/LEFTBANNER.PHP LOCATION1 NOT INSTALLED and ADMIN/MAIN_PHP LOCATION 1 NOT INSTALLED LOCAL COPY OF /MOD_FOLDER/BACKUPLIVING.PHP FOR INSTALLATION IS MISSING. So it appears there should be another file in the downloaded zip file? Thanks for your help in advance. I am really impressed with this program. Am looking forward to going live after I get my desktop genealogy file (RootsMagic 4) cleanedup. TNG has certainly spurred me to do that. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.