Search found 38 matches

by tiagocampos
26 Dec 2013 06:37
Forum: DOS Batch Forum
Topic: Batch to archive files
Replies: 54
Views: 44517

Re: Batch to archive files

Indeed that fixed it. I wasn't getting error messages, at least I couldn't see them cause the window shuts down too fast. I even tried doing some echos/pauses before and after that line to try and figure it out but no luck. Thanks for your help, now I'll test and see if the problem with the previous...
by tiagocampos
26 Dec 2013 06:22
Forum: DOS Batch Forum
Topic: Batch to archive files
Replies: 54
Views: 44517

Re: Batch to archive files

I've tested several times now and what's causing the script to break is this instruction: for /f "delims=" %%b in ('dir "????_??" /ad /b') if /i not "%%b"=="Archive" do ( If I replaced with the previous one it is ok: for /f "delims=" %%b in ('dir &qu...
by tiagocampos
10 Dec 2013 05:18
Forum: DOS Batch Forum
Topic: Batch to archive files
Replies: 54
Views: 44517

Re: Batch to archive files

Well I just replaced again and the zip worked fine :cry:
by tiagocampos
09 Dec 2013 09:08
Forum: DOS Batch Forum
Topic: Batch to archive files
Replies: 54
Views: 44517

Re: Batch to archive files

This is what I current have. I changed what you said. @echo off call :getdate today -30 set "folder=%cd%" :: get timestamp in YYYYMMDD_HHMMSS format for /f "delims=" %%a in ('wmic OS Get localdatetime ^| find "."') do set dt=%%a set dt=%dt:~0,8%_%dt:~8,6% :: To specify ...
by tiagocampos
09 Dec 2013 05:03
Forum: DOS Batch Forum
Topic: Batch to archive files
Replies: 54
Views: 44517

Re: Batch to archive files

Just had the chance to test it now.

The result was this http://i.imgur.com/cF6WA0v.png
He did everthing OK but didn't zip the folders at the end.
by tiagocampos
04 Dec 2013 04:58
Forum: DOS Batch Forum
Topic: Batch to archive files
Replies: 54
Views: 44517

Re: Batch to archive files

Well I saved the list of folders and exclusions used in 2 past runs where this issue occurred:

In the 1st the exclusions were:

Code: Select all

infoLog.txt

And the folders: http://pastebin.com/GhM6iP5M

In the 2nd the exclusions were:

Code: Select all

.csv

And the folders: http://pastebin.com/mp2HhVP5
by tiagocampos
03 Dec 2013 09:52
Forum: DOS Batch Forum
Topic: Batch to archive files
Replies: 54
Views: 44517

Re: Batch to archive files

What's really buzzing me is that this only happens when I do big runs. I was just testing with a single folder trying to recreate the error but it was ok. But when I run for all folders with sometimes 20.000 files each, this issue happens. Regarding your question, I don't think so. The script is not...
by tiagocampos
03 Dec 2013 05:36
Forum: DOS Batch Forum
Topic: Batch to archive files
Replies: 54
Views: 44517

Re: Batch to archive files

Hi again foxidrive, I've been experiencing some issues with the script lately. After finishing executing, the script deletes the zips from previous executions, leaving only the new ones in the folder Archive. I can't seem to find what's causing this behavior, can you please take a look? Here is the ...
by tiagocampos
04 Oct 2013 08:48
Forum: DOS Batch Forum
Topic: Batch: size of folders from a list
Replies: 12
Views: 8208

Re: Batch: size of folders from a list

Oh God...so stupid.

Thank you very much
by tiagocampos
03 Oct 2013 11:07
Forum: DOS Batch Forum
Topic: Batch: size of folders from a list
Replies: 12
Views: 8208

Re: Batch: size of folders from a list

Did that, but prompt closed with no results or log writen. Maybe the full code can help: @echo off :: To specify the location of the file from where we import the list of directories to take action set file=C:\Users\administrator-ch\Documents\sizebackups\folderslist.txt echo Updating log... for /f &...
by tiagocampos
03 Oct 2013 10:10
Forum: DOS Batch Forum
Topic: Batch: size of folders from a list
Replies: 12
Views: 8208

Re: Batch: size of folders from a list

Ok I runned the script for this 4 folders: A:\Ambidata A:\BackupSQL A:\DADOS A:\Vazio And this is what I get in the cmd: http://prntscr.com/1v0owp And the log file is like this: 2013-10-03;A:\DADOS;135.157.117.617 2013-10-03;A:\Ambidata;6.027.825.713 2013-10-03;A:\BackupSQL;637.279.136 No entry for ...
by tiagocampos
03 Oct 2013 09:02
Forum: DOS Batch Forum
Topic: Batch: size of folders from a list
Replies: 12
Views: 8208

Re: Batch: size of folders from a list

for /f "tokens=3-4" %%v in ('dir "%dirName%" /s ^| find /i "file(s)"') do ( set bytes=%%v ) :: To specify log folder and file set LOG_FOLDER=C:\Users\administrator-ch\Documents\sizebackups\LOGS set datetime="%date:~6,4%%date:~3,2%%date:~0,2% set LOG_FILE=%LOG_FOLD...
by tiagocampos
16 Sep 2013 04:09
Forum: DOS Batch Forum
Topic: Batch: size of folders from a list
Replies: 12
Views: 8208

Re: Batch: size of folders from a list

EDIT: Ignored it, it was an error with the log file (feature I added). The location of the log folder was incorrect. Sorry to waste your time.
by tiagocampos
13 Sep 2013 08:04
Forum: DOS Batch Forum
Topic: Batch: size of folders from a list
Replies: 12
Views: 8208

Re: Batch: size of folders from a list

I got an issue when my folders path has spaces, like for example: "C:\Program Files (x86)\MTSOMS\adapter-logs\AS61001"

The script doesn't recognize the path :cry:
by tiagocampos
13 Sep 2013 03:11
Forum: DOS Batch Forum
Topic: Batch: size of folders from a list
Replies: 12
Views: 8208

Re: Batch: size of folders from a list

Perfect, many thanks :)