Understanding codecs and containers

Understanding codecs and containers

Container is what we typically associate with the file format. Containers “contain” the various components of a video: the stream of images, the sound, and anything else. For example, you could have multiple soundtracks and subtitles included in a video file, if the container format allows it. Example of popular containers are OGG, Matroska, AVI, MPEG.

Codecs are ways of “coding” and “decoding” streams. Their job is typically to compress data (and decompress it when playing it back) so that you can store and transmit files with a smaller filesize. There are many codecs available out there, each with their strengths, weaknesses and peculiarities, and choosing the right codec with the right settings for the right situation is close to be a form of art in itself.

The relationship between containers and codecs

Schedule a Bash Shell Script in Windows

Yes, Cygwin make shell script happen in Windows. I need to do Rsync on some “folder” to some “Directory”, just make the bash file with rsync in side (/cygwin/home/Administrator/rsync_script.sh) then go to Schedule Task

New Task -> Name your task

Action -> New -> Start a Program
Path: C:\Cygwin\bin\bash.exe
Argument: -l -c “/home/Administrator/rsync_script.sh >> /home/Administrator/daily.log  2>&1”

Google Drive as a Service in Windows Server

Google Drive as a Service in Windows Server

I need to backup stuff to another Google Drive folder, it work when I finish install Google Drive, after I log out of the server, it stop working, because Google Drive was designed as a Personal app. To make it work as a service I need to run Google Drive by Task Scheduler with appropriate Permission, which mean the user install the app also a user running the task.

After install Google Drive -> Turn off start Google Drive at boot option

Then Go to Task Scheduler and follow the IMGs belows:

Screenshot from 2016-03-03 10:25:47

Screenshot from 2016-03-03 10:26:00

Screenshot from 2016-03-03 10:26:10

Screenshot from 2016-03-03 10:26:28

 

Schedule a Batch script in Windows

Schedule a Batch script in Windows

Here is the batch script, which remove everything in myfolder.

set folder="C:myfolder"
cd /d %folder%
for /F "delims=" %%i in ('dir /b') do (rmdir "%%i" /s/q || del "%%i" /s/q)

I put it on C:/rmStuffInMyfolder.bat

Schedule a Batch File to run automatically

Step 1: Create a batch file you wish to run and place it under a folder where you have enough permissions. For example under C drive.

Step 2: Click on Start and under search, type in Task and click open Task Scheduler.

Step 3: Select Create Basic Task from the Action pane on the right of the window.

Step 4: Under Create Basic Task, type in the name you like and click Next.

Step 5: From the Trigger select the option you like and click Next.

I chose Daily and clicked Next, which brought me to this screen.

Step 6: Then click on Start a Program and click Next.

Step 7: Now click on Browser and select the batch file you like to run.

Step 8: Finally, click on Finish to create the Task.

Now that we have created a Task, we have to make sure it runs with the highest privilege. Since we have UAC settings we have to make sure that when you run the file it should not fail if it does not bypass the UAC settings.

So click on Task Scheduler Library.

Then double click on the Task you just created.
Step 8: Click on Run with Highest privilege then click OK.

Congratulations!

How to schedule a Batch File to run automatically in Windows 10/8/7