Jump to content

Automatic restore points, Windows 7


ray5450

Recommended Posts


On 7/16/2020 at 8:05 AM, ray5450 said:

I take it, no one knows how to set this up?

Or maybe someone knows but he/she isn't going to tell. :unsure:

On 7/4/2020 at 7:53 PM, ray5450 said:

Thanks, for your response.  I am aware there is a setting to make a restore point with every start up, but that is not what I am trying to do.  I need to set task scheduler to create a restore point every 3 days.

To be picky, it seems to me like you are losing the final scope by focusing on the means.

There is no law stating that a restore point needs to be made by task scheduler.

You could have a script (batch/vbs/whatever) run at startup every time that checks if:
1) the day of the month is 1,4,7, etc (or 2,6,10, etc,)
2) there isn't a restore point already made today
and if both conditions are met starts a manual restore point backup.

jaclaz

 

Edited by jaclaz
Link to comment
Share on other sites

"Or maybe someone knows but he/she isn't going to tell."  --MSFN   Where People Go to Know  (?)

"There is no law stating that a restore point needs to be made by task scheduler."  --My question is specifically for task scheduler. 

"run at startup"  --Already discussed.  See above.

As to HarryTri:  I disabled restore point creation under system protection, disabled task scheduler creation, disabled antivirus, rebooted, re-enabled both, and waited some days, but no change.  This is a new install of Windows.

Link to comment
Share on other sites

5 hours ago, ray5450 said:

"Or maybe someone knows but he/she isn't going to tell."  --MSFN   Where People Go to Know  (?)

... and sometimes fail at it ...

5 hours ago, ray5450 said:

"There is no law stating that a restore point needs to be made by task scheduler."  --My question is specifically for task scheduler. 

I understand what your question was, but, since noone knows (or won't tell you ;)) how to use the specific tool you want to use to obtain the specific expected result, I suggested another possible way to obtain the same actual specific expected result.

I will use one of my re-known (and lousy :unsure:) carpenter's comparisons:

 I read your request as:
"I need to join two pieces of wood, I tried superglue but it didn't work."


To which I replied:
"You could try using the old school way, nails or screws and vinyl glue, instead. Rest assured that the two pieces of wood will remain joined"

jaclaz

 

 

Link to comment
Share on other sites

Thanks, for your response.  As I stated previously, I am occasionally making a manual one while this is not working right.  Making one every day will push them off the list too fast as the oldest one would be the one I would use, rather than one a few days old or less that would have the same problem as why I would need it.

Link to comment
Share on other sites

6 minutes ago, ray5450 said:

Thanks, for your response.  As I stated previously, I am occasionally making a manual one while this is not working right.  Making one every day will push them off the list too fast as the oldest one would be the one I would use, rather than one a few days old or less that would have the same problem as why I would need it.

I know that one per day i just "too much" and this is why i suggested to automate the making of a manual one through a conditional script that you can change so that the actual manual restore point is made ONLY when more conditions are met (two in the example, date and NOT an existing one):

On 7/16/2020 at 7:23 PM, jaclaz said:

You could have a script (batch/vbs/whatever) run at startup every time that checks if:
1) the day of the month is 1,4,7, etc (or 2,6,10, etc,)
2) there isn't a restore point already made today
and if both conditions are met starts a manual restore point backup.

jaclaz

Link to comment
Share on other sites

4 hours ago, ray5450 said:

You're right.  Something like that would work to, in effect, re-invent your own task scheduler.

Yep :), exactly. 

Let's call it  PHATS :w00t:, (Poorman's Half-@§§ed Task Scheduler).

A batch sketch:

@ECHO OFF
SETLOCAL ENABLEEXTENSIONS

:: Use WMIC to retrieve date and time
FOR /F %%A IN ('WMIC Path Win32_LocalTime Get /Format:list ^|FIND "="') DO SET my_%%A

:: Check that today is one of the "blessed" days
:: Every three days, this will however make a file on the 31st and one on the 1st of following month
:: AND there is no check about how old is last file
:: FOR /L %%A IN (1,3,31) DO IF %%A EQU %my_day% GOTO :do_something

:: OR Monday, Wednesday, Friday
FOR /L %%A IN (1,2,5) DO IF %%A EQU %my_DayOfWeek% GOTO :do_something
ECHO Not the right day, today is %my_day%, day of week #%my_DayOfWeek%
GOTO :EOF

:do_something
SET my_month=0%my_month%
SET my_month=%my_month:~-2,2%
SET my_day=0%my_day%
SET my_day=%my_day:~-2,2%
SET my_hour=0%my_hour%
SET my_hour=%my_hour:~-2,2%
SET my_minute=0%my_minute%
SET my_minute=%my_minute:~-2,2%
SET now=%my_year%%my_month%%my_day%_%my_hour%%my_minute%
SET now
FOR /F %%A IN ('DIR /b /O-N *_*.txt 2^>NUL') DO SET my_last=%%~nA&&GOTO :Out_of_loop
:Out_of_loop
IF NOT DEFINED my_last GOTO :do_cmd
IF %now:~0,8% EQU %my_last:~0,8% GOTO :Error_1
IF %now:~0,8% LSS %my_last:~0,8% GOTO :Error_2
IF %now:~0,6% LSS %my_last:~0,6% GOTO :do_cmd
SET /A Delta=%now:~0,8% - %my_last:~0,8%
IF %Delta% GEQ 3 GOTO :do_cmd
GOTO :EOF

:do_cmd
ECHO Imagine here a command that makes a restore point
ECHO and *somehow* names it %now%.txt
ECHO Something>%now%.txt
GOTO:EOF


:Error_1
ECHO Nothing to do, a today file exists.
PAUSE
GOTO:EOF

:Error_2
ECHO Nothing to do, a later than today file exists.
PAUSE
GOTO:EOF

jaclaz 

Link to comment
Share on other sites

2 minutes ago, ray5450 said:

omg, you wrote one?  I feel that is an effort beyond expectation.  Thank-you, so much.

Naah, don't worry, it is just a sketch, maybe 1/4 of the needed work, it needs to be made into actually producing the restore points, I have no idea where they are saved in Windows 7, and/or it is possible to use ISO yyyymmdd_hhmm  (or there is instead the need to write to a log/database of sorts), needs to be tested, and possibly made "foolproof", checking for elevation/Admin credentials, and what not.

The WMIC command to create a restore point should be something like:
wmic.exe /Namespace:\\root\default Path SystemRestore Call CreateRestorePoint "MyRestorePoint", 100, 7

that would become in the batch

wmic.exe /Namespace:\\root\default Path SystemRestore Call CreateRestorePoint "%now%", 100, 7

but that goes into the "description", not in the file name, so you will need to list descriptions, probably *like* here:
https://www.tenforums.com/tutorials/131901-see-list-all-available-system-restore-points-windows.html

jaclaz

 

Link to comment
Share on other sites

Looking around, I have seen quite a few Task Scheduler replacements/alternatives, and (only to confirm that you are not the only one) quite a few people stating that the built-in Task Scheduler is "unreliable".

A few:

https://www.splinterware.com/download/index.html

https://www.z-cron.com/download.html

https://web.archive.org/web/2019*/http://www.theabsolute.net/sware/files/tasksched.exe

a Java based one:
https://www.oliver-matuschin.de/en/projects/task-till-dawn

jaclaz

Link to comment
Share on other sites

I believe you, but until now, that has never been my own experience.  Task scheduler with restore points has always worked for me until now....for over 12 years.  My thoughts are, since it has always worked so well, it must be just some little thing that is causing a problem.  I was hoping to find out that little thing.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...