![]() ![]() My problem is that as soon as I get out from the subroutine where I change the access and modification times they revert back to the original ones! I don't have anything running in background and I also tested the script on a linux server with the same results To achieve this goal I get the FTP file modification time, convert it to timestamp and then use os.utime to change the access and modification dates of the files downloaded to match the FTP server ones. If they don't match then I download the new copy. I'm trying to develop a script that downloads files from an FTP that match certain criteria but if the file exists and I already have a copy of it on a local dir then I want to check file modification times. ![]() If you cannot see the download, please sign in or make an account.I've came across a problem in python 2.7.1 (running on Mac OS X 10.7.5) with the os.utime command Once this is done, run the uploadutime command to begin the process. Once that is done, drag and drop the utime_mysql folder into your addons directory, and remove the previous utime folder. Read the page to get the libmysql dll as well as proper installation for both. Please install the gm_mysqloo and libmysql dll files accordingly. In the case that you did not follow instructions properly, and happen to somehow mess up your database, I will NOT fix it for you. This addon comes as is, it's up to you to use it right. Use this following the use of utime_cleardb. utime_continue: This command will remove the limit that prevents multiple runs of the uploadutime command. Use this in the case that your server crashes midway during the data upload process. ![]() utime_cleardb: This command will empty the table of all of its data. uploadutime: This command will begin to upload all of the utime data from sv.db to the MySQL database. It is advised that if your host crashed, you download the files and do it off a personal server. If you feel that this data is not fully on there, please restart the server, run the command "utime_cleardb" followed by "utime_continue" then finally "uploadutime". A safety has been applied to prevent the data from being uploaded multiple times. Once this process is complete, there should be an automated restart triggered by the server, however if it doesn't work for some reason just restart manually when the message about the server restarting appears. There is also an option to have the server place before the servers hostname, which will let players know what is going on. A password is then placed on the server, and should not be changed to allow joins during the uploading process. This is to prevent any data altercation during upload, ensuring a safer upload. Doing this will EMPTY your server completely, as well as put a password on it. Running the command "uploadutime" will begin the process of uploading your data to the MySQL database. This works by running a simple console command, and ensures that it is nearly impossible for anything wrong to happen. Updated UI to be the same as the normal versionīiggest addition is the ability to upload current data from the server's sv.db file to the MySQL database and have it begin to use the MySQL data. Added color coding for the console messages Removed the two pointless table additions (steamid and playername) It's been quite a while since the last release of a Utime MySQL addon/update, so I decided to bring mine to the table. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |