Alle berichten van Willem

ffmpeg tips (en mencoder)

ffmpeg -i infile.mpg -map 0:1 -vn -ac 2 -ar 48000 -ab 256k -ss hh:mm:ss -t hh:mm:ss outfile.mp3

-map = selecteer de stream (zie de output van ffmpeg voor meer informatie)

-vn = Disable video recording

-ac = aantal kanalen

-ar = Set the audio sampling frequency (default = 44100 Hz)

-ab = Set the audio bitrate in kbit/s (default = 64)

-ss = Seek to given time position in seconds. “hh:mm:ss[.xxx]” syntax is also supported.

-t = Set the recording time in seconds. “hh:mm:ss[.xxx]” syntax is also supported.

How-to gids op: http://howto-pages.org/ffmpeg/

En tips om snel klaar te zijn http://www.tuxradar.com/content/ffmpeg-made-easy

Handige opties:

-target pal-dvd = Predefined settings
-aspect 4:3 = Aspect ratio videobeel
-b 2000k = Videobitrate
-r 10 = Videoframerate
-ar 22050 = Audio samplerate
-ab 64k = Audiobitrate
-aq 0 .. 9 = Audio quality

-acodec copy
-vcodec copy

-ss 00:11:37.458 -t 00:42:43.452 
-map 0.0:0.0 -map 0.2:0.1

Ondertiteling extract

ffmpeg -i file.mkv -vn -an -codec:s:0.1 srt sub.srt

Ondertiteling toevoegen

ffmpeg -i infile.mkv -vcodec copy -acodec copy -vf subtitles=sub.srt outfile.mkv

Fouten uit een (mpg) file halen:

ffmpeg -i "1003_20130405181500.mpg" -vcodec copy -acodec copy "/media/media/1003_20130405181500.mpg"

mencoder "1003_20130405181500.mpg" -oac copy -ovc copy -o "/media/media/1003_20130405181500.mpg"


Disable autorun in Microsoft Windows

Bron: http://www.us-cert.gov/cas/techalerts/TA09-020A.html

Disable AutoRun in Microsoft Windows

To effectively disable AutoRun in Microsoft Windows, import the following registry value:

      REGEDIT4

 

      [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\IniFileMapping\Autorun.inf]

 

    @=”@SYS:DoesNotExist”

To import this value, perform the following steps:

  1. Copy the text
  2. Paste the text into Windows Notepad
  3. Save the file as autorun.reg
  4. Navigate to the file location
  5. Double-click the file to import it into the Windows registry

Microsoft Windows can also cache the AutoRun information from mounted devices in the MountPoints2 registry key. We recommend restarting Windows after making the registry change so that any cached mount points are reinitialized in a way that ignores the Autorun.inf file. Alternatively, the following registry key may be deleted:

    HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\MountPoints2

Once these changes have been made, all of the AutoRun code execution scenarios described above will be mitigated because Windows will no longer parse Autorun.inf files to determine which actions to take. Further details are available in the CERT/CC Vulnerability Analysis blog. Thanks to Nick Brown and Emin Atac for providing the workaround.

Update:

Microsoft has provided support document KB953252, which describes how to correct the problem of NoDriveTypeAutoRun registry value enforcement. After the update is installed, Windows will obey the NoDriveTypeAutorun registry value. Note that this fix has been released via Microsoft Update to Windows Vista and Server 2008 systems as part of the MS08-038 Security Bulletin. Windows 2000, XP, and Server 2003 users must install the update manually. Our testing has shown that installing this update and setting the NoDriveTypeAutoRun registry value to 0xFF will disable AutoRun as well as the workaround described above.

Gentoo chroot in bestaande installatie

Chroot

mount /dev/sda3 /mnt/gentoo
mount /dev/sda1 /mnt/gentoo/boot
mount -t proc none /mnt/gentoo/proc
mount -o bind /dev /mnt/gentoo/dev
chroot /mnt/gentoo /bin/bash
env-update
source /etc/profile
export PS1=”(chroot) $PS1″

Kernel aanpassen

cd /usr/src/linux
make menuconfig

make && make modules_install
cp arch/x86/boot/bzImage /boot/kernel-2.6.27-r8   #for 32 bit
cp arch/x86_64/boot/bzImage /boot/kernel-2.6.27-r8     #for 64 bit

Informatie hardware

http://kmuto.jp/debian/hcl/

System rescue CD om lokaal windows wachtwoord te wijzigen

System rescue CD om lokaal windows wachtwoord te wijzigen:

Optie 1: Boot met ntpass

Optie 2: Start met linux

ntfs-3g /dev/sda1 /mnt/windows

optie:  force  Force the mounting even if the NTFS logfile is unclean. The logfile will be unconditionally cleared. Use this option with caution and for your own responsibility.

cd /mnt/windows/Windows/System32/config

chntpw SAM

Om SAM te zoeken: find . -iname ‘sam*’ -prin

Tip, om bootable USB-key te maken:UNetbootin

Windows 7 keyboard shortcuts

Windows 7 keyboard shortcuts

Veel werken ook in Windows XP / Vista

Toetsencombinatie Functie
Windows Logo + Tab Met Aero-effect door open applicaties bladeren (alternatief voor Alt + Tab)
Windows Logo + E Start Windows Explorer
Windows Logo + R Start Run Command
Windows Logo + F Open zoekvenster
Windows Logo + X Open Mobility Center
Windows Logo + L Lock het systeem
Windows Logo + U Open Ease Of Access Center (toegankelijkheidsopties)
Windows Logo + P Kies uitvoerbron voor videobron(nen)
Windows Logo + T Wandel door geopende Super Taskbar-items
Windows Logo + 1 t/m 0 Open bijbehorend venster in de taakbalk (van links naar rechts)
Windows Logo + S Open One Note Screen Clipping Tool (vereist OneNote)
Windows Logo + M Minimaliseer alle geopende vensters
Windows Logo + D Toon het bureaublad
Windows Logo + Spatiebalk Bekijk het bureaublad
Windows Logo + Pijl Omhoog Maximaliseer het geopende venster
Windows Logo + Pijl Omlaag Minimaliseer het geopende venster/herstel vorig formaat
Windows Logo + Pijl Links Verplaats venster naar links en neem helft van het scherm in
Windows Logo + Pijl Rechts Verplaats venster naar rechts en neem helft van het scherm in
Windows Logo + Shift + Pijl Links Verplaats venster naar linkermonitor (vereist dualmonitor-setup)
Windows Logo + Shift + Pijl Rechts Verplaats venster naar rechtermonitor (vereist dualmonitor-setup)
Control + muisklik op vastgepind taskbar-icoon Wandel door geopende Aero Peek-previews
Control + Shift + muisklik op vastgepind taskbar-icoon Start een nieuw venster van de applicatie met administrator-rechten
Shift + muisklik op vastgepind taskbar-icoon Start een nieuw venster van de applicatie
Alt + Pijl Omhoog Ga een directory omhoog (werkt in Windows Explorer)
Alt + Pijl Links/Rechts Ga een stap Terug/Vooruit (werkt in Windows Explorer)

Bron: Tweakers.net

Handige portage (Gentoo commando’s)

Portage information query tool

Voorbeeld:

portageq owners / [<filename>]

equery

Voorbeeld:

equery depends pkgspec

list all direct dependencies matching pkgspec

Voorbeeld forceren foute checksum ebuild

# ebuild –force /usr/portage/x11-misc/googleearth/googleearth-5.1.3506.3999_beta.ebuild manifest

Genereer nieuwe checksum

ebuild <naam>-<versie>.ebuild digest

Revdep Rebuild

# revdep-rebuild -i

Check op consistency

perl-cleaner all
emerge -uD world

eselect python set pythonXX
python-updater
emerge –depclean
revdep-rebuild

–backtrack=50

La File Fixer

# lafilefixer –justfixit

Outlook 2010 create rule when receiving “on behalf of”

When creating a rule to act on incoming messages in Outlook 2010 which are send ‘on behalf of’ the “from people or public group” option does not work. This option only checks the actual sender.

As workaround you can create a rule and let it check the ‘message header’. Check the ‘Internet headers’ in the message properties and use the ‘From’ field there, The format is something like “From: xxxx <xxxxx@xxxxx>”. Use this text in a rule “with specific words in the message header”

Thunderbird: Creating complex mails with inline images

If you create your HTML message in some other application, and insert it in the message by using Thunderbird’s Insert – HTML… dialog, then you can usually use that other application to add the moz-do-not-send attribute to each IMG tag. For example, the resulting tag might look like:

img src="http://static.mozillazine.org/common/images/blimp.png" moz-do-not-send="true"

Source: http://kb.mozillazine.org/Creating_complex_mails_with_inline_images

In an HTML-formatted message, you can send mail with a pointer to a picture rather than embedding the actual picture in the message. The advantage is that the message is much smaller. The disadvantage is that the picture is physically on another server; if the image is unavailable?now or in the future?your recipient will not see it. Some e-mail clients might also be configured to block remote images.

  1. In the Compose window, select “Insert -> Image”. The “Image Properties” dialog box will appear.
  2. Fill in the “Image Location” field with the URI of the picture. You can type it in if you know it, or you can paste it in. For example, in Firefox, right-click on the image and choose “Copy Image Location”. Then in Thunderbird right-click in the “Image Location” field to paste in the URI.
  3. Put some words in the “Alternate text:” field. If you do not, Thunderbird will refuse to send the message.
  4. Next, click on the “Advanced Edit” button. The “Advanced Property Editor” dialog will open.
  5. In the “Attribute:” field at the bottom, type moz-do-not-send.
  6. In the “Value:” field at the bottom, type true.
  7. Press the “OK” button to exit the “Advanced Property Editor” dialog and then press “OK” again to exit the “Image Properties” dialog.