Thursday 31 August 2017

computer building - What tools to test the reliability and stability of a newly built PC?

Just curious what everyone uses to stress test their machines.

Windows task scheduler not triggering a task on Windows 10

I have a task that is supposed to run a script I made, every 10 minutes, but it just doesn't seem to trigger it.


In the task scheduler it says that next run time is in 10 minutes, but when the time comes, nothing happens.


I have multiple triggers just because I was hoping at least one of them might work:



  • One time. At 0.00 - After triggered run every 10 minutes.

  • At log on of any user - After triggered run every 10 minutes.

  • On idle - After triggered run every 10 minutes.


Since "next run time" appears, you would think the triggers are working... Nothing happens though.


And yes, I am sure the script itself works. It's a vbscript, which I thought should work with the scheduler, but just in case, I made a batch to run the script and put the batch under the scheduled trigger, but neither way worked.


Any idea what's wrong?


EDIT: I now use a small program called system scheduler. My script is running fine with that and I don't imagine it uses much resources so I can just keep using that.


It would still be useful to figure out what's wrong with the windows task scheduler though, so answers are still appreciated.

command line - How do I find out what version of Linux I'm running?


Is there a way to determine what version (distribution & kernel version, I suppose) of Linux is running (from the command-line), that works on any Linux system?



Answer



The kernel is universally detected with uname:


$ uname -or
2.6.18-128.el5 GNU/Linux

There really isn't a cross-distribution way to determine what distribution and version you're on. There have been attempts to make this consistent, but ultimately it varies, unfortunately. LSB tools provide this information, but ironically aren't installed by default everywhere. Example on an Ubuntu 9.04 system with the lsb-release package installed:


$ lsb_release -irc
Distributor ID: Ubuntu
Release: 9.04
Codename: jaunty

Otherwise, the closest widely-available method is checking /etc/something-release files. These exist on most of the common platforms, and on their derivatives (i.e., Red Hat and CentOS).


Here are some examples.


Ubuntu has /etc/lsb-release:


$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=9.04
DISTRIB_CODENAME=jaunty
DISTRIB_DESCRIPTION="Ubuntu 9.04"

But Debian has /etc/debian_version:


$ cat /etc/debian_version
5.0.2

Fedora, Red Hat and CentOS have:


Fedora: $ cat /etc/fedora-release
Fedora release 10 (Cambridge)

Red Hat/older CentOS: $ cat /etc/redhat-release
CentOS release 5.3 (Final)

newer CentOS: $ cat /etc/centos-release
CentOS Linux release 7.1.1503 (Core)

Gentoo:


$ cat /etc/gentoo-release
Gentoo Base System release 1.12.11.1

I don't have a SUSE system available at the moment, but I believe it is /etc/SuSE-release.


Slackware has /etc/slackware-release and/or /etc/slackware-version.


Mandriva has /etc/mandriva-release.


For most of the popular distributions then,


$ cat /etc/*{release,version}

will most often work. Stripped down and barebones "server" installations might not have the 'release' package for the distribution installed.


Additionally, two 3rd party programs you can use to automatically get this information are Ohai and Facter.


Note that many distributions have this kind of information in /etc/issue or /etc/motd, but some security policies and best practices indicate that these files should contain access notification banners.


Related: How to find out version of software package installed on the node?, .


Does rEFInd need code in the MBR to boot windows on a Mac?


I have read many posts regarding installing and booting Windows on Mac computers. Many procedures use rEFInd to boot a BIOS install of Windows. The procedures do not seem to indicate any installation of code in the MBR. So either the assumption is there is already code in the MBR from a previous install or rEFInd does not require such code to boot Windows. Does anyone know the answer?



Answer



Both rEFIt and rEFInd will place a copy of SYSLINUX MBR boot code in the MBR if the MBR is not already bootable and if appropriate boot code exists in a partition. That said, boot code should exist in the MBR, although it might be destroyed by partitioning tools that assume the first 440 bytes of the MBR on a GPT disk should be zeroed out, as is normally the case for EFI-bootable GPT disks.


This brings up another point, though: Windows 8 (and presumably Windows 10) installs pretty well in EFI mode on many Macs. When installed in this way, no BIOS-mode boot code is necessary, in either the MBR or in the Windows partition(s). An EFI-mode installation is likely to be safer because there's no need for the dangerous hybrid MBR that Macs use to dual-boot OS X and earlier versions of Windows. The catch to this type of installation is that Disk Utility and some other OS X tools will create a hybrid MBR if you try to prepare the disk for Windows -- for instance, by setting up a FAT partition. When the Windows installer, booted in EFI mode, sees the hybrid MBR, it will complain that it can't install to an MBR disk. You can work around this problem by using any number of tools (such as gdisk: Type x, then n, then w), but it can be frustrating and confusing if you don't understand the nature of the problem or how to fix it.


ubuntu - Make an existing VM immutable


With XP security support coming to an end, but needing to use some software that will only run under XP (and some other software that just needs windows) I'd like to make my XP VM a bit more secure.


I've done quite a few things (disabling unnecessary services, avoiding admin logon where possible, installing avg, firefox with noscript etc. if web is needed), but I'd like a clean copy that I can easily roll back from - or run to work on my data.


I've cloned the VM (so I can have a version that keeps the antivirus up to date), but would like to set one copy to an immutable HDD. I don't see any options for doing that, and everything on the web that I've found is several versions old and has more problems than solutions. I would have thought this was a fairly common topic at the moment. My host is Ubuntu Precise.


By "immutable" I use the term as I understand it from the virtualbox documentation I've read: a disk which is read-only, i.e. changes to that disk are discarded when the session is closed. This means that rather than taking a copy of a clean copy to restore it to a known state all I have to do is boot it.


As an aside or a point of reference I've seem something similar on internet cafe machines, where when your time is up the guest OS restores to a clean state for the next user, but there you never get anywhere near the host.



Answer



This works for me:



  1. Halt the VM if it's running.

  2. Open the "Storage" settings for the VM where the HDD image is attached. Detach the image.

  3. From the VM Virtualbox Manager window, select File->Virtual Media Manager.

  4. In the media manager window, select the hard drive image that you want to change.

  5. Select the "Modify" button, or right-click on the image and select "Modify...". Change the image to immutable and click "OK".

  6. Return to the storage settings for the VM and re-attach the HDD image to the VM.


How do I tell Firefox to only keep persistent cookies from sites I want?


Is there a way to tell Firefox to only keep persistent cookies from sites I want? I don't mind "session cookies" from all sites, but persistent cookies, I only want from a handful of sites to "keep me logged in".



Answer



You can pick and choose which sites you want to keep cookies from or want to block from ever getting.



Tools > Options > Privacy



The Options dialog will appear. This is where you set your cookies preferences.


Firefox privacy option


To allow cookies to be set in the first place, check the following box:



☑ Accept cookies from sites



To keep all cookies from sticking, essentially turning them into session cookies (ones that won't be there next time you restart Firefox), select the option that will destroy them when you exit the browser:



Keep until: I close Firefox



To allow persistent cookies, ones that will be there next time Firefox is started, click Exceptions...


Firefox persistent cookies


Type in the domain of the site(s) you want to always accept and keep cookies from. Click Allow for each.


If instead you would like to prevent certain sites from ever storing cookies, click Block.


When you've finished entering all the sites, click Close, then OK and you're done.


Sync Google Calendar with work Outlook/Exchange without details


I'm using the free Google Calendar Sync to import my work calendar from Outlook into my 'life' calendar at Google Calendar. I would like to do a 2 way sync, but without my 'life' calendar events' details being imported into my 'work' Outlook calendar (i.e. Show colleagues that can see my work calendar I'll be unavailable at 15:00, but without the details).


I was unable to achieve this using various schemes, namely using the free Google tool to sync 2 way to a 2nd Google Calendar account to which I shared my 1st calendar without details (I guess it doesn't work since it does not sync non-primary calendars).


I'm sure this is a common problem for the working person.... any ideas?


p.s. I'm using Outlook 2007 if that matters.



Answer



You may have tried this already and it might not work... but try it!


Click on settings in the top-right corner of Google Calendar.

Click on the name of your Personal Calendar

Click on *Share this Calendar*

Click *Make this Calendar Public*

Click *Share only my free/busy information (Hide details)*

images - How to compress / reduce the size of JPEG photos for archiving?



I have 50,000 high resolution JPEG photos, where a couple of them might occasionally be needed, about once a year.


I wanted to zip them to save disk space, except that zipping gives no space benefit - so trying to reduce the images disk usage using winzip, winrar or 7zip was not successful.


Is there any software or algorithm similar to zip to compress image size on hard disk for storage without loosing any image information?



Answer



From Wikipedia:



Image compression may be lossy or lossless. Lossy methods are especially suitable for natural images such as photographs (e.g JPEG files) in applications where minor (sometimes imperceptible) loss of fidelity is acceptable to achieve a substantial reduction in bit rate.



JPEG optimizing is considered to be a very efficient method to reduce JPEG file size while preserving the image quality. The goal is to reduce the size of photos without affecting their perceptual (noticeable) quality. The optimized image should look identical to the original image to humans, even if it was reduced to 30% of its original size or even less.


There are several tools for JPEG optimization, mostly command-line tools (libraries); the most popular ones are jpegtran & jpegoptim (Google PageSpeed recommends using them too).


If you're looking for a more user-friendly tool, I recommend using JPEGmini. It's an online service, and it's free for personal use. I don't know if it's the best tool to use in order to optimize thousands of photos (see FAQ), but from my experience, it's doing a great job optimizing JPEG photos.


windows - How to pipe output and duplicate it to STDOUT?



How can I pipe the output of one program to another, but also have it appear on screen.


For example, to duplicate what winds up on the clipboard in dir | clip, or to see what's happening along the way in longer chains.



Answer



If you have a copy of tee that runs on Windows, such that dir | tee NUL | clip loads the clipboard, but doesn't display anything on the screen (behaving as you would expect dir | clip to), try dir | tee con | clip.  (con is short for “console”; it’s Windows’ equivalent of /dev/ttynul, naturally, is Windows’ equivalent of /dev/null.)


windows 7 - How to prevent scheduled tasks from running as soon as computer wakes up?

Example: I have a task that is scheduled for 6 am every day (only if I'm logged on). If my computer sleeps/hibernates all night until 9am, upon waking up the task will then run even though it missed its 6am schedule. I don't want that to happen as it's important that the task runs only at 6am.


I thought that unchecking the "Run task as soon as possible after a scheduled start is missed" setting would prevent this, but it doesn't. Is there another setting I should try so that the task will run only if the computer is on at the scheduled time (and will wait until the next scheduled time if it misses it)?


An example of my settings:


enter image description here

How to merge Windows registry hives directly without converting them to an intermediate text based file?

Help! I'm going to get fired if I can't figure out how to do this by tomorrow.



Microsoft Windows stores its registry databases (known as "registry hives" there's actually a backstory to the origin of this name, but I digress) in a proprietary binary format.


Answer this correctly or you lose your job:




  1. Let H-sub-A be the registry hive of Computer A, and let H-sub-B be the registry hive of Computer B.




  2. Create a registry hive H-sub-A-prime (in the native binary format) that contains all of the registry keys and values in both H-sub-A and H-sub-B. If there is overlap, let the value from H-sub-B overwrite the value in H-sub-A.




  3. Sure, you can import a text-based patch file (e.g., "FOO.REG") to modify the registry, but can you merge two registry hives in their native binary format?




Answers that involve exporting the registry to a text file (e.g., "FOO.REG") will receive no credit. You may only use software included with Microsoft Windows (any version) and / or third-party tools that are free of charge.


Wednesday 30 August 2017

windows 7 - How do I hide the English language from the language bar?

My operating system is in English.


I have two keyboards: Spanish and Japanese. I speak Spanish natively, and I'm learning Japanese, but to write in English I just use the Spanish keyboard.


The problem is that in the language bar I see three keyboard layouts, and so pressing Alt+Shift changes the languages between those three: Spanish, Japanese and English.


Is there any way to disable this? Or am I doomed because I use the OS in English?


Here is an image explaining the situation:


enter image description here

windows 7 - How to communicate between two PCs on the same LAN?


Another user and I are on the same LAN and often wish to send each other URLs or several photos, or such. Is there a program or a feature that would allow us to communicate simply? like a local PC-to-PC IM?


Windows 7 (PC 1) to Windows XP (PC 2).



Answer



LAN Chat is a LAN based IM client, very simple and private to a local network


windows 7 - Can not access internet through VPN

I have a home wifi network that I want to access remotely via VPN.


I want to access files/folder that I have shared and the internet access through my home wifi (not from my local wifi) - That is I want the default bhaviour of VPN


My router (speedtouch 780WL) at home gets assigned a dynamic ip address from my ISP. In my router I have a feature to assign public IP to a computer. Which I have done so. Hence when my home computer is turned on it is assigned the public ip address of my router.


As a result of the above change in my router configuration the ip that gets assigned to my person computer is like 117.7.3.30 other computers on the same network are assigned ip addresses like 192.168.1.65 , 192.168.1.66 and so on.


The gateway/router ip address within my home netwrok is 192.168.1.254


Now from outside the network I can access 117.7.3.30 ip which accesses my home computer which is perfectly fine.


The problem


In my home computer (windows 7 pro) In the network connection I have created a new incoming network connection using default settings. which has 'Allow other to access my local network' and 'assign ip address automatcally using dhcp' enabled


When I remotely connect to my home network thourgh vpn I can access my files/folders on the network but there is no Internet access.


The VPN connection status says


IPV4 Connectivity no Internet access.  
IPV6 Connectivity no Network access.

The description says


 DHCP enabled no
IPv4 address 192.168.1.66
IPv4 subnet mask 255.255.255.255
IPv4 default gateway Empty
IPv4 DNS server 192.168.1.254
IPv4 WINS server Empty
Netbios over tcpip enabled Yes

Any ideas why internet is not accessible ? My suspicion is the default gateway which is empty in the details of VPN connection should have been 192.168.1.254 which address of the router. Even though in the VPN client connection properties -> Networking IPV4 -> properties -> Advanced -> use default gateway on remote network is checked.

Remote Desktop connection is ignoring saved credentials


I have an RDP (Remote Desktop connectin) file.
When I view/edit the file I can see that the username and password are stored in it,
but when I connect to the remote server using the file the server shows me a login prompt with empty username and password.


Does anyone know what may be the problem?
Is there a server setting that controls this behavior?



Answer



Turns out this indeed is configurable via Group Policy (in my case controlled via Windows domain). See this link: http://support.microsoft.com/kb/281262


Batch convert Word documents to PDFs


How do I batch convert many Word documents and have them saved as [originalfilename].pdf?



Answer



This is how I would do it:



  1. Download CutePDF writer

  2. Set the writer as your default printer (you can change it back later)

  3. Place all your .doc files in the same folder

  4. Highlight all the files, right-click, Print


Only downside is that you have to click Ok once for each file.


7 zip - Create 7-Zip SFX executable

I'm playing around with 7-Zip to create a self-extracting archive (SFX) executable. I followed the documentation, but I wasn't able to get any close. I'm using the 7-Zip 32 bit and the 7-Zip extra 32 bit.


Here is where I'm stuck first to create an SFX file you need to call the following script:


copy /b 7zS.sfx + config.txt + archive.7z archive.exe

This will generate an archive.exe that will have the config.txt file to run the appropriate program. Here is how the config.txt file look like:


;!@Install@!UTF-8!
Title="7-Zip 4.00"
BeginPrompt="Do you want to install the 7-Zip 4.00?"
RunProgram="setup.exe"
;!@InstallEnd@!`

This will generate archive.exe.


Now further down in the documentation it tells you how to add a file. I need to compress the setup.exe file so I use the following script.


7z a -sfx a.exe setup.exe

I'm confused about this example. Do I use archive.exe instead of a.exe? And if I do that, I get an error saying archive.exe is not a supported archive type.


If I kept the name a.exe and setup.exe to the a and also added the archive.exe file into it using the previous script, and all it did was extracting the file into the local folder instead of executing it.


Why is this happening?

sleep - Win 7 won't stay asleep

My Win 7 RC will not stay "Asleep". After about two minutes it wakes up. It won't go to sleep after the TV show is recorded and finished either. So, my computer is on most of the time. What can I do?

linux - How to install wireless drivers without internet access?


I have a wireless card that needs the Broadcom B4311 Rev. 1 driver but I don't have a way to download that driver since I don't have wireless access since the driver isn't installed.


I'm running Linux Mint Debian x64.



Answer



You can download a few files from another computer and install the firmware.


Ignore the wget's, just put the corresponding file in the working directory instead of launching the command.


There are instructions here http://wireless.kernel.org/en/users/Drivers/b43


For a similar chip (which probably uses the same firmware) there are more straightforward instructions: https://wiki.ubuntu.com/Testing/Laptop/Lucid/Reports/AcerAspireOneD150#Post-install%20fixes


Windows 10 wake up from sleep is very slow

I just recently did a clean install of Windows 10 Pro.
OS runs smoothly, boot time is not so bad (under 30s), but wake-up time is IMO terribly slow, at least compared to Windows 7, where I could work with system immediately.
In Windows 10 on the other hand, I have to wait 10 - 15 secs before OS becomes usable. I can't type my password right away, because login screen is unresponsive. With password on login disabled, I still have to wait like 15 secs before any programs/apps will respond.

Tuesday 29 August 2017

How to fix a keyboard layout on each Windows 10 computer?


I use Windows 10 with the same Microsoft account on 3 different computers, each one with a different physical keyboard layout: ITA, UK, DE.


In "Control panel - Clock and International settings - Language" I have ITA as display language with ITA/DE/UK keyboard layouts, followed by ENG(US) with only UK layout.


In the same window I opened "Advanced settings" where I set an override (second drop-down list) to the default ("the first one on the list") language/keyboard: that would be ITA/ITA, while I want (on this computer) ITA/DE.


However, when now I log in in the other computers, I get ITA/DE there as well, while each computer should have a different one, being the physical keyboards different: ITA/DE here, ITA/UK on the second one and ITA/ITA on the third one.


If I change one, they all change. And if I don't apply the override, the issue seems to be the same.


Basically the last used language AND keyboard settings are stored on the cloud and applied wherever I log in.


How to set Windows 10 to remember, PER computer, the last used language/keyboard layout settings, without having that setting follow me?



Answer



You should be able to modify that within the synchronization settings on each machine:



  1. Press WinKey + S

  2. Type Sync your settings and press Enter


  3. In the subsequent window, switch Language preferences to Off


    Sync your settings




subst - How to delete Windows 7 virtual drive


I created a virtual drive using "SUBST" command . But i can not delete now .


Can anybody tell me how can I delete this virtual drive.



Answer



If using the command SUBST X: /D does not work then try rem or delete the occurrence of the SUBST command in the autoexec.bat file & reboot.


If using Windows 7, try to open your prompt window as Administrator and then run the SUBST X: /D normally


photos - Referencing a specific figure in Microsoft Word 2003


Referring to the screenshot below:


alt text


I want to be able to reference the figure in the body of the text properly without having to change them manually every time I add a figure label before that body of text. However, I don't know how to do it aside from adding caption labels, which won't work for cases where I have more than one reference to the figure (at least I don't know how to do that properly anyway). How would you recommend accomplishing that?



Answer



It's done by Insert -> Reference -> Cross Reference.


regex - Export all regular expression matches in Textpad or Notepad++ as a list


In Textpad or Notepad++ is there an option to export all the matches for a regular expression find, as a single list?


In a big text file, I am searching for tags (words enclosed in % %), using regular expression %\< and \>%, and want all the matches as a single list, so that I can remove duplicates using Excel and get a list of unique tags.



Answer



You can achieve this by using Backreferences and Find and Mark functionality in Notepad++.




  1. Find the matches using regex (say %(.*?)% ) and replace it by \n%\1%\n , after this we will have our target word in separate lines (i.e. no line will have more than one matched word)




  2. Use the Search-->Find-->Mark functionality to mark each line with regex %(.*?)% and remember to tick 'Bookmark Line' before marking the text



  3. Select Search-->Bookmark-->Remove Unmarked Lines

  4. Save the remaining text. It is the required list.


mp4 - Best settings for FFMpeg with NVENC


I'm using my FFMPEG with the suport of my GPU (NVENC) to convert files from my satelite receiver (SD, mpeg2 .TS-Files) into h264 .mp4-files


Here is the line i'm using


ffmpeg -i "e:\input.ts" -vcodec h264_nvenc -preset slow -level 4.1
-qmin 10 -qmax 52 "e:\output.mp4"

But the quality is not as good as expected. And the full power of my system is not used:


enter image description here


Only 11% GPU and 30% CPU usage.


Question: Are there a few improvements I can make to improve the quality by equal file size and use more calculating power of my Geforce GTX 1080?


I found a few parameters from 林正浩 to change but -preset slow should already be the best quality approach right?



Answer



Here is a rough guide to tuning the encoder:


We'll start from the basics, as it would be detrimental to jump into the conclusion that a quick barrage of options will suddenly improve expected output without understanding the desired objectives and expectations:


1. Start by understanding the encoder's options.


For NVENC-based encoders, start with learning the options each encoder takes (Note that I'm on Linux, which is why I'm using xclip to copy the codec options to the clipboard prior to pasting them here):


(a). For the H.264 encoder:


ffmpeg -hide_banner -h encoder=h264_nvenc | xclip -sel clip

Output:


Encoder h264_nvenc [NVIDIA NVENC H.264 encoder]:
General capabilities: delay
Threading capabilities: none
Supported pixel formats: yuv420p nv12 p010le yuv444p yuv444p16le bgr0 rgb0 cuda
h264_nvenc AVOptions:
-preset E..V.... Set the encoding preset (from 0 to 11) (default medium)
default E..V....
slow E..V.... hq 2 passes
medium E..V.... hq 1 pass
fast E..V.... hp 1 pass
hp E..V....
hq E..V....
bd E..V....
ll E..V.... low latency
llhq E..V.... low latency hq
llhp E..V.... low latency hp
lossless E..V....
losslesshp E..V....
-profile E..V.... Set the encoding profile (from 0 to 3) (default main)
baseline E..V....
main E..V....
high E..V....
high444p E..V....
-level E..V.... Set the encoding level restriction (from 0 to 51) (default auto)
auto E..V....
1 E..V....
1.0 E..V....
1b E..V....
1.0b E..V....
1.1 E..V....
1.2 E..V....
1.3 E..V....
2 E..V....
2.0 E..V....
2.1 E..V....
2.2 E..V....
3 E..V....
3.0 E..V....
3.1 E..V....
3.2 E..V....
4 E..V....
4.0 E..V....
4.1 E..V....
4.2 E..V....
5 E..V....
5.0 E..V....
5.1 E..V....
-rc E..V.... Override the preset rate-control (from -1 to INT_MAX) (default -1)
constqp E..V.... Constant QP mode
vbr E..V.... Variable bitrate mode
cbr E..V.... Constant bitrate mode
vbr_minqp E..V.... Variable bitrate mode with MinQP (deprecated)
ll_2pass_quality E..V.... Multi-pass optimized for image quality (deprecated)
ll_2pass_size E..V.... Multi-pass optimized for constant frame size (deprecated)
vbr_2pass E..V.... Multi-pass variable bitrate mode (deprecated)
cbr_ld_hq E..V.... Constant bitrate low delay high quality mode
cbr_hq E..V.... Constant bitrate high quality mode
vbr_hq E..V.... Variable bitrate high quality mode
-rc-lookahead E..V.... Number of frames to look ahead for rate-control (from 0 to INT_MAX) (default 0)
-surfaces E..V.... Number of concurrent surfaces (from 0 to 64) (default 0)
-cbr E..V.... Use cbr encoding mode (default false)
-2pass E..V.... Use 2pass encoding mode (default auto)
-gpu E..V.... Selects which NVENC capable GPU to use. First GPU is 0, second is 1, and so on. (from -2 to INT_MAX) (default any)
any E..V.... Pick the first device available
list E..V.... List the available devices
-delay E..V.... Delay frame output by the given amount of frames (from 0 to INT_MAX) (default INT_MAX)
-no-scenecut E..V.... When lookahead is enabled, set this to 1 to disable adaptive I-frame insertion at scene cuts (default false)
-forced-idr E..V.... If forcing keyframes, force them as IDR frames. (default false)
-b_adapt E..V.... When lookahead is enabled, set this to 0 to disable adaptive B-frame decision (default true)
-spatial-aq E..V.... set to 1 to enable Spatial AQ (default false)
-temporal-aq E..V.... set to 1 to enable Temporal AQ (default false)
-zerolatency E..V.... Set 1 to indicate zero latency operation (no reordering delay) (default false)
-nonref_p E..V.... Set this to 1 to enable automatic insertion of non-reference P-frames (default false)
-strict_gop E..V.... Set 1 to minimize GOP-to-GOP rate fluctuations (default false)
-aq-strength E..V.... When Spatial AQ is enabled, this field is used to specify AQ strength. AQ strength scale is from 1 (low) - 15 (aggressive) (from 1 to 15) (default 8)
-cq E..V.... Set target quality level (0 to 51, 0 means automatic) for constant quality mode in VBR rate control (from 0 to 51) (default 0)
-aud E..V.... Use access unit delimiters (default false)
-bluray-compat E..V.... Bluray compatibility workarounds (default false)
-init_qpP E..V.... Initial QP value for P frame (from -1 to 51) (default -1)
-init_qpB E..V.... Initial QP value for B frame (from -1 to 51) (default -1)
-init_qpI E..V.... Initial QP value for I frame (from -1 to 51) (default -1)
-qp E..V.... Constant quantization parameter rate control method (from -1 to 51) (default -1)
-weighted_pred E..V.... Set 1 to enable weighted prediction (from 0 to 1) (default 0)
-coder E..V.... Coder type (from -1 to 2) (default default)
default E..V....
auto E..V....
cabac E..V....
cavlc E..V....
ac E..V....
vlc E..V....

(b). For the HEVC/H.265 encoder:


ffmpeg -hide_banner -h encoder=hevc_nvenc | xclip -sel clip

Output:


Encoder hevc_nvenc [NVIDIA NVENC hevc encoder]:
General capabilities: delay
Threading capabilities: none
Supported pixel formats: yuv420p nv12 p010le yuv444p yuv444p16le bgr0 rgb0 cuda
hevc_nvenc AVOptions:
-preset E..V.... Set the encoding preset (from 0 to 11) (default medium)
default E..V....
slow E..V.... hq 2 passes
medium E..V.... hq 1 pass
fast E..V.... hp 1 pass
hp E..V....
hq E..V....
bd E..V....
ll E..V.... low latency
llhq E..V.... low latency hq
llhp E..V.... low latency hp
lossless E..V.... lossless
losslesshp E..V.... lossless hp
-profile E..V.... Set the encoding profile (from 0 to 4) (default main)
main E..V....
main10 E..V....
rext E..V....
-level E..V.... Set the encoding level restriction (from 0 to 186) (default auto)
auto E..V....
1 E..V....
1.0 E..V....
2 E..V....
2.0 E..V....
2.1 E..V....
3 E..V....
3.0 E..V....
3.1 E..V....
4 E..V....
4.0 E..V....
4.1 E..V....
5 E..V....
5.0 E..V....
5.1 E..V....
5.2 E..V....
6 E..V....
6.0 E..V....
6.1 E..V....
6.2 E..V....
-tier E..V.... Set the encoding tier (from 0 to 1) (default main)
main E..V....
high E..V....
-rc E..V.... Override the preset rate-control (from -1 to INT_MAX) (default -1)
constqp E..V.... Constant QP mode
vbr E..V.... Variable bitrate mode
cbr E..V.... Constant bitrate mode
vbr_minqp E..V.... Variable bitrate mode with MinQP (deprecated)
ll_2pass_quality E..V.... Multi-pass optimized for image quality (deprecated)
ll_2pass_size E..V.... Multi-pass optimized for constant frame size (deprecated)
vbr_2pass E..V.... Multi-pass variable bitrate mode (deprecated)
cbr_ld_hq E..V.... Constant bitrate low delay high quality mode
cbr_hq E..V.... Constant bitrate high quality mode
vbr_hq E..V.... Variable bitrate high quality mode
-rc-lookahead E..V.... Number of frames to look ahead for rate-control (from 0 to INT_MAX) (default 0)
-surfaces E..V.... Number of concurrent surfaces (from 0 to 64) (default 0)
-cbr E..V.... Use cbr encoding mode (default false)
-2pass E..V.... Use 2pass encoding mode (default auto)
-gpu E..V.... Selects which NVENC capable GPU to use. First GPU is 0, second is 1, and so on. (from -2 to INT_MAX) (default any)
any E..V.... Pick the first device available
list E..V.... List the available devices
-delay E..V.... Delay frame output by the given amount of frames (from 0 to INT_MAX) (default INT_MAX)
-no-scenecut E..V.... When lookahead is enabled, set this to 1 to disable adaptive I-frame insertion at scene cuts (default false)
-forced-idr E..V.... If forcing keyframes, force them as IDR frames. (default false)
-spatial_aq E..V.... set to 1 to enable Spatial AQ (default false)
-temporal_aq E..V.... set to 1 to enable Temporal AQ (default false)
-zerolatency E..V.... Set 1 to indicate zero latency operation (no reordering delay) (default false)
-nonref_p E..V.... Set this to 1 to enable automatic insertion of non-reference P-frames (default false)
-strict_gop E..V.... Set 1 to minimize GOP-to-GOP rate fluctuations (default false)
-aq-strength E..V.... When Spatial AQ is enabled, this field is used to specify AQ strength. AQ strength scale is from 1 (low) - 15 (aggressive) (from 1 to 15) (default 8)
-cq E..V.... Set target quality level (0 to 51, 0 means automatic) for constant quality mode in VBR rate control (from 0 to 51) (default 0)
-aud E..V.... Use access unit delimiters (default false)
-bluray-compat E..V.... Bluray compatibility workarounds (default false)
-init_qpP E..V.... Initial QP value for P frame (from -1 to 51) (default -1)
-init_qpB E..V.... Initial QP value for B frame (from -1 to 51) (default -1)
-init_qpI E..V.... Initial QP value for I frame (from -1 to 51) (default -1)
-qp E..V.... Constant quantization parameter rate control method (from -1 to 51) (default -1)
-weighted_pred E..V.... Set 1 to enable weighted prediction (from 0 to 1) (default 0)

2. Understand the hardware's limitations, and stick to sane defaults first before applying options:


Refer to this answer for the hardware limitations you'll run into with NVENC, especially for HEVC encodes on Pascal.


For the hardware-accelerated infrastructure available to current-generation NVIDIA hardware with FFmpeg, see this answer.


Then, using that information, proceed to the next step.


3. Syntax is critical:


Here is the order in which you have to pass arguments to FFmpeg:


(a). Call up the binary.


(b). Pass any arguments to FFmpeg (such as -loglevel to it directly) before declaring inputs.


(c). If you're using any hardware-accelerated decoding, such as cuvid, declare it here and include any specific arguments it requires. At this point, it would be imperative to mention that decoders have specific constraints, such as expected input resolutions, supported codecs, etc, and as such, it's recommended that in production, to determine and validate the need for hardware-accelerated decoders as failure at this stage results in a failed encode and is unrecoverable. In fact, the MPV devs have mentioned this repeatedly, don't rely on hardware-accelerated decoding for mission-critical content delivery.


(d). Declare your inputs. For streams, use the URL and if needed, prepend extra flags (such as buffer sizes) as needed. For local resources (on an accessible filesystem), the absolute file path is needed.


(e). Optionally, insert a filter. This is needed for functions such as resize,pixel format conversations, de-interlacing, etc. Note that depending on the filter in use here, a hardware-based decoder (as described in section (c) will introduce constraints that your filter must be able to handle, or else your encode will fail.


(f). Call up the appropriate video and audio encoders, and pass necessary arguments to them, such as mappings, bitrates, encoder presets, etc. When it comes to bitrates, ensure that your desired values are set via the -b:v, -maxrate:v and -bufsize:v options. Do not leave these blank. This is a good starting point on why these values matter. As always, start by specifying a preset. Scroll down to the bottom to see notes on the performance impact of presets with this particular encoder.


(g). Whereas FFmpeg can deduce the required output format of a file depending on the selected extension of the output file, it is recommended to explicitly declare the output format (through the -f option) so that extra options can be passed to the underlying muxer if needed, as is often the case with streaming formats such as HLS, mpegts and DASH.


(h). The absolute path to the output file.


With your example above, quoted as:


ffmpeg -i "e:\input.ts" -vcodec h264_nvenc -preset slow -level 4.1
-qmin 10 -qmax 52 "e:\output.mp4"

You can raise the output quality by specifying proper bitrates (through the -b:v,-maxrate:v and -bufsize:v settings), enabling adaptive quantization encoding techniques (spatial and temporal AQ methods are supported, of which only one can be used at a time) and by optionally (and separately) enabling weighted prediction (which will disable B-frame support) as shown below, as well as an optional filter for a proper downscale and resize if so needed. The example below shows a snippet handling mpegts input encoded in mpeg2:


ffmpeg -loglevel debug -threads 4 -hwaccel cuvid -c:v mpeg2_cuvid -i "e:\input.ts" \
-filter:v hwupload_cuda,scale_npp=w=1920:h=1080:interp_algo=lanczos \
-c:v h264_nvenc -b:v 4M -maxrate:v 5M -bufsize:v 8M -profile:v main \
-level:v 4.1 -rc:v vbr_hq -rc-lookahead:v 32 \
-spatial_aq:v 1 -aq-strength:v 15 -coder:v cabac \
-f mp4 "e:\output.mp4"

Warning: Note that weighted prediction (-weighted_pred) cannot be enabled at the same time as adaptive quantization. Attempting to do so will result in encoder initialization failure.


The snippet above assumes that the input file is an MPEG2 stream. If that's not the case, switch to the correct CUVID decoder after analyzing it:


ffprobe -i e:\input.ts

If its' H.264/AVC, modify the snippet as shown below:


ffmpeg -loglevel debug -threads 4 -hwaccel cuvid -c:v h264_cuvid -i "e:\input.ts" \
-filter:v hwupload_cuda,scale_npp=w=1920:h=1080:interp_algo=lanczos \
-c:v h264_nvenc -b:v 4M -maxrate:v 5M -bufsize:v 8M -profile:v main \
-level:v 4.1 -rc:v vbr_hq -rc-lookahead:v 32 -spatial_aq:v 1 \
-aq-strength:v 15 -coder:v cabac \
-f mp4 "e:\output.mp4"

I have noticed that enabling either adaptive quantization OR weighted prediction options for NVENC may introduce issues with stability, particularly with specific device driver combinations. Where possible, consider using B-frames (no more than 3) combined with the generic option -refs:v set to 16 or thereabouts, instead of toggling on AQ and weighted prediction:


ffmpeg -loglevel debug -threads 4 -hwaccel cuvid -c:v h264_cuvid -i "e:\input.ts" \
-filter:v hwupload_cuda,scale_npp=w=1920:h=1080:interp_algo=lanczos \
-c:v h264_nvenc -b:v 4M -maxrate:v 5M -bufsize:v 8M -profile:v main \
-level:v 4.1 -rc:v vbr_hq -rc-lookahead:v 32 -refs:v 16 \
-bf:v 3 -coder:v cabac \
-f mp4 "e:\output.mp4"

With Turing, in particular, you may also benefit from enabling B-frames for reference as shown below (see the toggle -b_ref_mode:v middle):


ffmpeg -loglevel debug -threads 4 -hwaccel cuvid -c:v h264_cuvid -i "e:\input.ts" \
-filter:v hwupload_cuda,scale_npp=w=1920:h=1080:interp_algo=lanczos \
-c:v h264_nvenc -b:v 4M -maxrate:v 5M -bufsize:v 8M -profile:v main \
-level:v 4.1 -rc:v vbr_hq -rc-lookahead:v 32 -refs:v 16 \
-bf:v 3 -coder:v cabac -b_ref_mode:v middle \
-f mp4 "e:\output.mp4"

An extra note on thread counts (passed to ffmpeg via the -threads option):


More encoder threads beyond a certain threshold increases latency and will have a higher encoding memory footprint. Quality degradation is more prominent with higher thread counts in constant bitrate modes and near-constant bitrate mode called VBV (video buffer verifier), due to increased encode delay. Keyframes need more data then other frame types to avoid pulsing poor quality keyframes.


Zero-delay or sliced thread mode has no delay, but this option farther worsens multi-threads quality in supported encoders.


It's therefore wise to limit thread counts on encodes where latency matters, as the perceived encoder throughput increase offsets any advantages it may bring in the long term.


And since you're on Windows, you may want to remove the shell escapes \ above as I'm writing this from a Unix box testing the command above.


Notes on performance impact with presets and interlaced encoding considerations:


For high throughput, low latency performance, ensure you're using either llhp or llhq presets. This is most useful for workloads such as live streaming where broader compatibility with a wider variety of devices is expected, and as such, performance crippling features such as B-frames can be omitted altogether for a good trade-off between higher bit-rates in use and throughput. Higher presets (such as the default medium) have rapidly diminishing returns in quality output while at the same time incurring significant slowdowns in encoder throughput. The quality difference between llhp and llhq as measured by Netflix's VMAF is virtually negligible, yet the encoder's performance boost (over ~30% on my test bed) with the former is definitely appreciable.


For the llhp and llhq presets, as well as other presets in use, you can also override the in-built rate-control methods by passing the -rc:v arguments as exposed by the encoder options. For example, with constant bit-rate encoding, you can specify -rc:v cbr (which is significantly faster than the cbr_ld_hq rate control method, bringing an additional ~20% boost to throughput). Note that the preset selected has the greatest impact on throughput, followed by the preset options (such as the rate control method in use) that you can optionally override if desired.


Consider your encoding workflow and adjust as necessary. Your mileage will definitely vary, based on your source content, filter chains in use, specific pltform configuration variables (such as your GPU and driver versions), etc.


In the same breath, note that NVIDIA has explicitly disabled interlaced encoding on Turing across all tiers, even in the 1660Ti line that uses the older Volta NVENC encoder. If you require interlaced encoding support, please switch to Pascal or older SKUs instead.


Is overclocking legal?



Is overclocking your CPU and GPU classified as being legal ? If so, why don't manufacturers make overclocking easier so that just about anyone is able to play around with it ? - at own risk of course.



Answer



Manufacturers are not obliged to make easy any course of action just because it happens to not be illegal. I don't know what jurisdiction you are in, but I think you'd be hard pressed to find any language in any law that states that overclocking is illegal.


I think the key is the "at own risk" - if you make overclocking too easy, people will start playing with voltages, timings and frequencies without having any idea about how they interact and what the consequences may be. At best, then, you get an unstable system, and at worst, you can destroy the hardware. For which the manufacturer almost certainly will get the blame. What company wants to make it very easy for the customer to put the company in that position?


wireless networking - Tips for locating my stolen computer?

I'm in a bit of a panic, my new Powerbook laptop was stolen. I had no mobile me, or security software installed on the computer. I have the MAC address of the computer as well as the serial number. Is there a hacky way to do this?


I was even thinking perhaps of trying to use bluetooth, I know I had it set to discoverable. and I know the "name" of the computer, perhaps there is app that can scan the names of bluetooh computers in the vicinity?


If there some third party you can get to scan the internet for your MAC address?


Any glimmer of hope would really help.

Monday 28 August 2017

How to convert Html files to Pdf?


The title say it all, I want a 100% accurate tool to convert a HTML page to a PDF document.



Answer



Check out wkhtmltopdf. It uses the Webkit layout engine (as used in Safari, Chrome, etc.).


dns - Ping to dnsmasq's host resolvesto 127.0.0.1


I've just set up dnsmasq in my home lan for the first time. I got it as DHCP and DNS.


Something strange is that when I ping DEV01 (which has dnsmasq) it resolves to 127.0.0.1 and I don't know why it is doing so.


jorgee@jorgee:~$ nslookup dev01 192.168.1.2
Server: 192.168.1.2
Address: 192.168.1.2#53

Name: dev01
Address: 127.0.1.1

Is anything else to configure?



Answer



The solution is to change the hosts file to reflect the IP Address of the network interface (ie change 127.0.0.1 to 192.168.1.2).


This works because DNSMasq is translating the Domain name into the IP address based on the contents of the "hosts" file, and the hosts file is set to point the domain name to 127.0.0.1 which is a special address each machine on the Internet has so it can refer to itself even without a valid Internet connection - but 127.0.0.1 does not work so well for a server.


linux - What do the parentheses and number after a Unix command or C function mean?


I keep seeing parentheses and a number after a command in Unix or Linux or C function.


For example: man(8), ftok(2), mount(8), etc.


What do these mean? I see them in man too.



Answer



Manpage sections.



  1. Common UNIX command that can be used by all users. e.g. ls(1)

  2. Unix and C system calls e.g. mmap(2)

  3. C library routines for C programs e.g. system(3)

  4. Special files e.g. sudoers(4)

  5. System file formats e.g. lmhosts(5)

  6. Games e.g. fortune(6)

  7. Miscellaneous e.g. regex(7)

  8. System administration commands that is run by root only e.g. iwconfig(8)

  9. (?Linux specific) e.g.ksoftirqd(9)


The reason behind sections is that there are things sharing manual pages - mkdir(1) is the command used to create a directory whereas mkdir(2) is a system call that can be used to create a directory in a C program. Thus the different sections.


Annotated References [1,2] (as suggested):
http://www.gsp.com/support/man/ - The FreeBSD manpages arranged according to sections
http://manpages.unixforum.co.uk/man-pages/linux/suse-linux-10.1/ - SUSE manpages arranged according to sections
http://www.december.com/unix/ref/mansec.html - Yet another table for manpage sections. Initial basis of the list (See older edits of this post for details)


[1] explanations and examples are spontaneous fabrications in my head, for the matter.
[2] not that it is academically sound, but request for reference is one of the thing that slowed the growth of wikipedia. skeptics are trying to get others reference everything and some of the contributors just get way too annoyed to further answer anything, not that those who try to add useless/baseless stuff are properly removed from the pool (they just get the reference-request tag tagged onto their additions, contents not removed...)


microsoft word - Transform linked images to embedded images


I have imported a HTML report into word by opening it (open index.html in Word) and copy / paste the result as an annex into my Doc.


It worked fine, except that all the images (200 of them) are actually links to the images on my hard drive. Hence, when I send the document to my co-workers, they don't have the images.


How can I tell MS-Word to embed these images into the document itself?


If you have the procedure to do it for one image, I might be able to record a macro or write a visual-basic macro.



Answer



I found the solution here, the keyword was "unlinking images".


Here is the procedure for Word 2007.



  1. Press Ctrl+A to select the entire document.

  2. Click the large Microsoft Office button in the top left corner, select Prepare, then click Edit Links to Files (or press Alt+E+K).
    All links should be selected—if they're not, then make sure you've saved the document as a *.doc file, OR select all the files listed by scrolling to the end of the list and then using Shift+click to select the last in the range.

  3. Select the Save picture in Document check box.

  4. Click OK.


ubuntu 17.04 - Deny non-root users to mount devices?

I don't like the idea of a non-root user being able to mount partitions on my system (or mount them with write-privileges to be more specific). Even though mount only works for root users, my file manager dolphin can mount partitions without root access. I came across this answer, but removing my user from plugdev didn't change anything. Then I found out that udisksctl might have to do something with it, but I couldn't find a way to disable udisksctl for users (editing /usr/share/polkit-1/actions/org.freedesktop.udisks2.policy didn't change anything), so I just renamed /usr/bin/udisksctl and restarted and... dolphin can still mount partitions.


Now my question: How can I make mounting partitions only possible for root users?

linux - tmux disregarding the configuration file

I just installed tmux on Ubuntu 10.04 and tried to remap the prefix key to C-a by creating the file ~/.tmux.conf with these lines:


set-option -g prefix C-a
unbind-key C-b

When starting tmux, both regularly and with -f ~/.tmux.conf, the prefix is effectively the same default C-b


There are no errors or warnings whatsoever.


Any idea what's wrong with the loading of the conf?

hard drive - HDD vs SSD durability



I heard that SSD are less durable than HDD. Is it true ?



Answer



My first reaction to your question was: "My experience is exactly the opposite." Read on for exactly why, but first some background...


Both spinning and solid state drives have a limited life-span. There are some that are of the opinion that SSDs have as good or better a life-span than similar spinning hard drives given the same usage patterns.


Note however that not all SSDs are created equal. There are SLC drives such as the Intel X25-E, which tend to be much more expensive ($300 for a 32GB drive), but also are faster at writes and are more durable. The other architecture is called MLC, and is less expensive but may not be as good during writes as SLC and also may not last as long, largely because the memory cells have to be re-written in larger chunks. However, newer SSDs have better management firmware and last quite well.


But, back to your question... Everyone in my small company is running SSDs on their laptops. I've been running an Intel X25-M in mine for at least a year, maybe closer to two. I'd never go back to a spinning disc in my main laptop because of durability.


If you drop a laptop and the hard drive is spinning, you are almost certainly going to need to replace the hard drive. Earlier this year I dropped my laptop while it was running and after that it wouldn't even power on. I basically had to have everything but the CPU, RAM, and SSD replaced (motherboard, display, most of the parts of the case...). 3 or 4 years earlier I had a similar drop with a spinning drive. It survived for around a week after that, but quickly started generating errors.


So, in a laptop or other bump-prone environment like a carputer: SSDs are more durable hands down.


Another thing to consider though is how they fail. SSDs fail because they can no longer erase the cells. SSDs don't overwrite data, they tend to have a pool of unused blocks that they erase and make ready for use, and writes of existing blocks are sent to these new locations, rather than erasing existing data and writing it. Spinning hard drives tend to fail because the mechanical parts wear out and they start generating errors while writing and reading.


So one theory is that when the SSDs fail because of write cycle issues. you can still read the data off the drive, you just can't write anymore. Effectively making your SSD a read-only copy of your data when it failed.


My experience so far is fairly limited, less than a dozen drives over a couple of years for SSD versus over a thousand drives over 15 years for spinning. However, so far I do not feel that SSDs durability compared to spinning discs is insufficient, even for non-laptop use. Some of the very early SSDs were real crap, we had one vendor's 16GB SSD that died after a few weeks of use, and the replacement also died after a few weeks of use. However, current products, since the first generation Intel X25-M, I've been very happy with.


windows - Does compression on a TrueCrypt drive compromise the security?


I choose “Compress drive to save disc space” under drive properties.



Answer



The compression should have no effect on the security offered by TrueCrypt.


If the compression is applied before the encryption, i.e. at the filesystem level hosted within an encrypted file/partition then the data will still be as well encrypted as it would be uncompressed. No one would know it was compressed data until they'd managed to decrypt some of it anyway.


If the compression is applied after the encryption then it will have little or no effect either on security or space used - in fact it would most likely back-fire and result in wasting space - so you'll just be wasting CPU cycles. Data encrypted with cryptographically safe algorithms should not have enough redundancy for the compression algorithm to find.


windows 7 - Multiple User VPN

I am looking for a cheap or free solution to be able to connect multiple people via VPN to a host computer. Each person should not be able to see what the others are doing while logged in. Is this possible and if so where do I start my hunt?


Update: I was not sure what server, was just thinking of doing it on say a win7 desktop. Just looking into having 2-3 users have access to a program without each seeing each other.


Basically, I know nothing and want to know if this is a possibility for me.

windows 7 - Security Update for Microsoft Malware Protection Engine (Advisory 4022344)

According to https://technet.microsoft.com/en-us/library/security/4022344 the patch for this will be installed automatically. I've checked just now and all pending important updates have indeed been installed on the machine, with a subsequent reboot.


The relevant diagnostic is Windows Defender engine version.


'Advisory Details' says 1.1.13701.0 bad, 1.1.13704.0 good.


I've checked Windows Defender on my machine (Windows 7 x64), and it says 1.1.13701.0 even though all pending important updates are installed.


'Suggested Actions' says 'For affected software, verify that the Microsoft Malware Protection Engine version is 1.1.10701.0 or later.' This contradicts the table earlier on the page.


Which of these is correct? If the first one is correct, what are you supposed to do when Windows says all important updates are already installed?

ffmpeg - converting video to audio OGG results in wrong metadata duration


I'm converting mpeg video to ogg audio file using -vn option:


ffmpeg -i video.avi -acodec libvorbis -vn sound.ogg


The output:


ffmpeg -i video.avi -acodec libvorbis -vn -y sound.ogg
ffmpeg version 0.8, Copyright (c) 2000-2011 the FFmpeg developers
built on Jun 23 2011 14:21:12 with gcc 4.5.3
configuration: --enable-gpl --enable-version3 --enable-memalign-hack --enable-runtime-cpudetect --enable-avisynth --enable-bzlib --enable-frei0r --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libfreetype --enable-libgsm --enable-libmp3lame --enable-libopenjpeg --enable-librtmp --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxavs --enable-libxvid --enable-zlib
libavutil 51. 9. 1 / 51. 9. 1
libavcodec 53. 7. 0 / 53. 7. 0
libavformat 53. 4. 0 / 53. 4. 0
libavdevice 53. 1. 1 / 53. 1. 1
libavfilter 2. 23. 0 / 2. 23. 0
libswscale 2. 0. 0 / 2. 0. 0
libpostproc 51. 2. 0 / 51. 2. 0
Input #0, avi, from 'video.avi':
Metadata:
encoder : Lavf54.25.105
Duration: 00:00:10.03, start: 0.000000, bitrate: 269 kb/s
Stream #0.0: Video: mpeg4, yuv420p, 505x404 [PAR 1:1 DAR 5:4], 25 tbr, 25 tbn, 25 tbc
Stream #0.1: Audio: mp3, 44100 Hz, stereo, s16, 160 kb/s
Output #0, ogg, to 'sound.ogg':
Metadata:
encoder : Lavf53.4.0
Stream #0.0: Audio: libvorbis, 44100 Hz, stereo, s16, 64 kb/s
Stream mapping:
Stream #0.1 -> #0.0
Press [q] to stop, [?] for help
size= 62kB time=00:00:10.02 bitrate= 50.3kbits/s
video:0kB audio:57kB global headers:4kB muxing overhead 1.072614%

video.avi orignal size is 10.02 sec


After conversion ffmpeg -i sound.ogg gives that size is 4.91 sec:


ffmpeg -i alice10s.ogg
ffmpeg version 0.8, Copyright (c) 2000-2011 the FFmpeg developers
built on Jun 23 2011 14:21:12 with gcc 4.5.3
configuration: --enable-gpl --enable-version3 --enable-memalign-hack --enable-runtime-cpudetect --enable-avisynth --enable-bzlib --enable-frei0r --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libfreetype --enable-libgsm --enable-libmp3lame --enable-libopenjpeg --enable-librtmp --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxavs --enable-libxvid --enable-zlib
libavutil 51. 9. 1 / 51. 9. 1
libavcodec 53. 7. 0 / 53. 7. 0
libavformat 53. 4. 0 / 53. 4. 0
libavdevice 53. 1. 1 / 53. 1. 1
libavfilter 2. 23. 0 / 2. 23. 0
libswscale 2. 0. 0 / 2. 0. 0
libpostproc 51. 2. 0 / 51. 2. 0
Input #0, ogg, from 'sound.ogg':
Duration: 00:00:04.91, start: 0.000000, bitrate: 102 kb/s
Stream #0.0: Audio: vorbis, 44100 Hz, stereo, s16, 64 kb/s
Metadata:
ENCODER : Lavf53.4.0
At least one output file must be specified

NB! The file it self sound.ogg lasts 10 seconds if played in player, nothing is trimmed.


The options -q and -map are not supported on my ffmpeg version which is 0.8


UPD: It seems that there is a OGG problems in pre 1.x version. I wonder if its possible to work them around.



Answer



Well, based on the comments, ogg support is broken in your old ffmpeg build.


You need to work around somehow; with a separate ogg encoder, or something.


As an aside, if you haven't, you should ask your hosting provider to install a newer ffmpeg. clearly this one is borked.


display - Desktop PC (Monitor) Won't Boot, MOBO Doesn't Beep, But HDD and Fans Spin


Here's what happens when I try to boot my PC: The fans spin, the HDD sounds normal, mobo light turns on, but monitor won't turn on.


At first I thought it was a problem with my monitor itself, but when I disconnect the VGA cable from the GPU, it shows the "No Signal" message. The moment I plug it back in, it goes blank and the power light (on the monitor) blinks steadily.


I tried connecting the VGA cable directly to the board but same output.


Then I thought it might be a problem with the RAM so I tried disconnecting one stick first, and booting. No beeps, fans spin, HDD sounds normal, mobo light's on, but monitor won't turn on.


Then I tried disconnecting both sticks. And, some-freaking-how, the same output! No beeps (no beeps!). Fans spin. HDD sounds normal. Mobo light turns on, but the monitor won't turn on.


What is going on here?




UPDATE 1: I just noticed the HDD activity light (on the front of the CPU) is not blinking when I try to turn the PC on. But, again, like I said, the HDD itself sounds normal. Spinning fine, no recurring clicks.




UPDATE 2: The PC turns itself off after a while; like maybe 15 seconds. I'm pretty sure this is a new symptom. Sometimes, it restarts itself, then switches back off another 15 or so seconds later. Sometimes, it stays off the first time. As of this moment, as I watch this happen, my RAM sticks are disconnected, my GPU is as well, and my monitor is plugged into the onboard graphics card. BIOS battery's in, BIOS jumper's in the right place (I'd tried clearing the BIOS earlier), and my HDD is connected.


Note: Still no beeping.




!!! UPDATE 3: I replaced the motherboard, and it started working !!!




Monitor's an LG


Board's an Intel DG31PR


CPU's an Intel i5 3337u


GPU's an ATI Radeon HD 4350


HDD's a regular Seagate 1TB


Please feel free to ask followup questions; I'm sure I've forgotten to include some detail or the other.




!!! UPDATE 3: I replaced the motherboard, and it started working !!!



Answer



I replaced the motherboard, guys, and it started working.


security - How to properly secure a wireless home network


I'm soon going to be setting up a wireless network for me and some buddies and (hopefully) making it secure. I have some questions and concerns regarding this and figured someone here could give me a hand and steer me in the right direction.




  • I have a WRT55AG (version 2) loaded with the factory firmware. I've heard that it's possible to load your own firmware onto routers like these. Is it worth it? What can be achieved with it?




  • I was wondering what kind of security I should use on my wireless. Ideally I would want all devices to be 'accepted', but I'm not sure how to accomplish this. I'm guessing it has something to do with MAC addresses, but I don't know the first thing about them. It would be great that ALONG WITH encryption (I'm told WPA2 is the best), every device would need to be added to a list of some sort before even being able to access the AP.




  • Another feature I was thinking of would be completely hiding my wireless from showing up on other people's computer. Is this possible (like an SSID broadcast thing). Is it worth the trouble?




  • One more option I was looking to implement would be bandwidth calculators. Ideally something in the router to measure the amount of bandwidth being used and how much has been used for that month (this has to do with bills and limits, obviously). Is it possible to throttle down speed when a certain limit is reached?




These are alot of points but I was hoping someone who has more knowledge than me in this subject could give me a hand and a few pointers. Hopefully all this is possible and I'm not dreaming :)



Answer



Ok I'll address the points that I can: Yes it is possible to upgrade, or change the firmware on your router to another type. In doing so you will gain access to a far greater set of settings that you wouldn't already have on the factory firmware. Have a look at this article for a good idea of how to do it using DD-WRT: http://www.howtogeek.com/56612/turn-your-home-router-into-a-super-powered-router-with-dd-wrt/


WPA2 is a great encryption method which basically lets anyone who knows your passphrase connect. What you are also talking about is MAC address filtering which basically adds another layer of security to the connection meaning that if you add MAC filtering to the connection then although you know the passphrase if your MAC address is not in the table you won't be able to connect. A MAC address is just basically unique identifier associated to a specific piece of hardware. You would need to know the devices MAC address before they could connect as you would have to add it to the table in the router's security settings section.


Turning off your SSID is easily possible. That way your network would not show up when a computer or device scans for available networks. People trying to connect would have to do so manually having to enter your SSID name in the connect to dialogue box. Is it worth it? Well it is just another layer of security so yes if that is what you want. Bear in mind though that any serious hacker worth their salt could bypass this without much effort.


Bandwidth calculators. If you want this then that pretty much makes the decision about point 1 for you. You will need to change the firmware on the router if you want this functionality.


I would have a read of that article above and then decide if you are comfortable doing what it suggests. Good Luck.


fonts - How do I replace Windows 10's emoji?


I'd like to replace Microsoft's Segoe UI Symbol emoji globally with Noto Color Emoji's (since it has country flags and, more importantly, I think they're adorable). Unfortunately, Windows tells me it's not a valid font file.



  • Is there a hidden way to install this font and give it priority?

  • If not, how hacky would it be to replace them anyway?



Answer



Well, it's not like Microsoft deliberately disabled the support of Noto Emoji. More simply it just outright does not support the format that Noto uses.


While almost all fonts you deal with are OpenType-based, there are several different colour-font extensions to OpenType – Segoe UI Emoji uses Microsoft's own format (layered vector drawings in COLR/CPAL), while Noto Emoji Color uses Google's own (bitmap images in CBDT/CBLC). There's also Adobe's "SVG " and Apple's "sbix" format.


Noto is originally drawn in SVG format, so it includes Adobe's "SVG " table alongside Google's bitmaps, because that's simple enough. But the Microsoft layered format is quite different, so I'm not sure if automatic conversion would be easy or even possible.


See also issue #43 "NotoColorEmoji.ttf not a valid font in Windows" on GitHub for a more detailed explanation.




A while ago, there used to be an "Adobe Type Manager" adding support for Type-1 fonts, back when Windows only supported TrueType. But I haven't heard of anything that would add support for different kinds of emoji fonts...


Maybe you'll like the new Segoe Emoji that Build 14316 brings?




Update: Microsoft says that the 2016 "Anniversary" update finally supports all the above formats.


Sunday 27 August 2017

encryption - Decrypt files encrypted with TrueCrypt


I have a usb pen memory crypted with TrueCrypt.


Is there a way to decrypt ( without TrueCrypt ) files encrypted with TrueCrypt in linux ?



Answer



TrueCrypt volumes can only be decrypted with TrueCrypt itself.


New video card HIS 7790 OC 1GB: sytem doesn't boot


I've upgraded my old video card Gygabyte 7750 to HIS 7790 IceQ Turbo. After installation of card onto mobo, plugging power into video card and powering on, system starts but doesn't boot. Power is on, fans rotate, but there's no video signal. I don't even see BIOS POST screen.


PSU: Chieftec 450-80p
MB: MSI H61M-P20 (G3)
CPU: Intel g850
RAM: Goodram 2x4GB (1333)
HDD: 64GB Crucial m4 SSD + 80GB HITACHI sata2
MON: AOC i2369Vm (connected via hdmi)


System consumes very little power, so it's definitely not a PSU insufficiency problem.


EDIT: SOLVED by updating mobo BIOS



Answer



Thank you all guys, but as i suspected, the problem was definitely not in my PSU. Fortunately, I came across a similar post here and I assumed my problem may be the same. So, i updated my mobo BIOS and... The problem is FIXED!


finder - How to use Automator to give a GUI to ditto?


How do I create an Automator workflow, service or folder action to use ditto. The intention here is to use ditto to merge folders and/or files avoiding the unacceptable Finder's behavior of replacing the folder/file by the new one.



Answer



Create a Service that receives folders in Finder. Add a single Run AppleScript action to it with the following script code:


on run {input, parameters}
set dest to choose folder with prompt "Select destination:"
set dest_path to (POSIX path of dest) as text
set src_paths to ""
repeat with idx from 1 to count (input)
set src_paths to src_paths & (quoted form of (POSIX path of item idx of input as text)) & " "
end repeat
set cmd to "ditto " & src_paths & quoted form of dest_path
do shell script cmd
end run

The script will execute


ditto selectedFolder1 selectedFolder2 selectedFolderN folderChosenInDialog

Assign a keyboard shortcut for convenient access in System Preferences » Keyboard » Keyboard Shortcuts » Services.


linux - Load balancing with multiple gateways


I have to different ISPs, each on each own network. The main connects via ethernet and the secondary via wifi. The two networks have no relation at all. I just connect to them simultaneously. The reason I want to load balance between them is to achieve higher Internet speeds. Note: I have no advanced network hardware. Just my pc and the two routers that I have no access... main network:


if: eth0
gw: 192.168.178.1
my ip: 192.168.178.95
speed: 400 kbit/s

secondary network:


if: wlan0
gw: 192.168.1.1
my ip: 192.168.1.95
speed: 300 kbit/s

A diagram to explain the situation:


enter image description here


I'm on Arch Linux x64. I use netcfg to configure the interfaces Configs:


# /etc/network.d/main
CONNECTION='ethernet'
DESCRIPTION='A basic static ethernet connection using iproute'
INTERFACE='eth0'
IP='static'
ADDR='192.168.178.95'

# /etc/network.d/second
CONNECTION='wireless'
DESCRIPTION='A simple WEP encrypted wireless connection'
INTERFACE='wlan0'
SECURITY='wep'
ESSID='wifi_essid'
KEY='the_password'
IP="static"
ADDR='192.168.1.95'

And I use iptables to load balance, rules:


#!/bin/bash
/usr/sbin/ip route flush table ISP1 2>/dev/null
/usr/sbin/ip rule del fwmark 101 table ISP1 2>/dev/null
/usr/sbin/ip route add table ISP1 192.168.178.0/24 dev eth0 proto kernel scope link src 192.168.178.95 metric 202
/usr/sbin/ip route add table ISP1 default via 192.168.178.1 dev eth0
/usr/sbin/ip rule add fwmark 101 table ISP1
/usr/sbin/ip route flush table ISP2 2>/dev/null
/usr/sbin/ip rule del fwmark 102 table ISP2 2>/dev/null
/usr/sbin/ip route add table ISP2 192.168.1.0/24 dev wlan0 proto kernel scope link src 192.168.1.95 metric 202
/usr/sbin/ip route add table ISP2 default via 192.168.1.1 dev wlan0
/usr/sbin/ip rule add fwmark 102 table ISP2
/usr/sbin/iptables -t mangle -F
/usr/sbin/iptables -t mangle -X
/usr/sbin/iptables -t mangle -N MARK-gw1
/usr/sbin/iptables -t mangle -A MARK-gw1 -m comment --comment 'send via 192.168.178.1' -j MARK --set-mark 101
/usr/sbin/iptables -t mangle -A MARK-gw1 -j CONNMARK --save-mark
/usr/sbin/iptables -t mangle -A MARK-gw1 -j RETURN
/usr/sbin/iptables -t mangle -N MARK-gw2
/usr/sbin/iptables -t mangle -A MARK-gw2 -m comment --comment 'send via 192.168.1.1' -j MARK --set-mark 102
/usr/sbin/iptables -t mangle -A MARK-gw2 -j CONNMARK --save-mark
/usr/sbin/iptables -t mangle -A MARK-gw2 -j RETURN
/usr/sbin/iptables -t mangle -A PREROUTING -j CONNMARK --restore-mark
/usr/sbin/iptables -t mangle -A PREROUTING -m comment --comment "this stream is already marked; escape early" -m mark ! --mark 0 -j ACCEPT
/usr/sbin/iptables -t mangle -A PREROUTING -m comment --comment 'prevent asynchronous routing' -i eth0 -m conntrack --ctstate NEW -j MARK-gw1
/usr/sbin/iptables -t mangle -A PREROUTING -m comment --comment 'prevent asynchronous routing' -i wlan0 -m conntrack --ctstate NEW -j MARK-gw2
/usr/sbin/iptables -t mangle -N DEF_POL
/usr/sbin/iptables -t mangle -A DEF_POL -m comment --comment 'default balancing' -p tcp -m conntrack --ctstate ESTABLISHED,RELATED -j CONNMARK --restore-mark
/usr/sbin/iptables -t mangle -A DEF_POL -m comment --comment 'default balancing' -p udp -m conntrack --ctstate ESTABLISHED,RELATED -j CONNMARK --restore-mark
/usr/sbin/iptables -t mangle -A DEF_POL -m comment --comment 'balance gw1 tcp' -p tcp -m conntrack --ctstate NEW -m statistic --mode nth --every 2 --packet 0 -j MARK-gw1
/usr/sbin/iptables -t mangle -A DEF_POL -m comment --comment 'balance gw1 tcp' -p tcp -m conntrack --ctstate NEW -m statistic --mode nth --every 2 --packet 0 -j ACCEPT
/usr/sbin/iptables -t mangle -A DEF_POL -m comment --comment 'balance gw2 tcp' -p tcp -m conntrack --ctstate NEW -m statistic --mode nth --every 2 --packet 1 -j MARK-gw2
/usr/sbin/iptables -t mangle -A DEF_POL -m comment --comment 'balance gw2 tcp' -p tcp -m conntrack --ctstate NEW -m statistic --mode nth --every 2 --packet 1 -j ACCEPT
/usr/sbin/iptables -t mangle -A DEF_POL -m comment --comment 'balance gw1 udp' -p udp -m conntrack --ctstate NEW -m statistic --mode nth --every 2 --packet 0 -j MARK-gw1
/usr/sbin/iptables -t mangle -A DEF_POL -m comment --comment 'balance gw1 udp' -p udp -m conntrack --ctstate NEW -m statistic --mode nth --every 2 --packet 0 -j ACCEPT
/usr/sbin/iptables -t mangle -A DEF_POL -m comment --comment 'balance gw2 udp' -p udp -m conntrack --ctstate NEW -m statistic --mode nth --every 2 --packet 1 -j MARK-gw2
/usr/sbin/iptables -t mangle -A DEF_POL -m comment --comment 'balance gw2 udp' -p udp -m conntrack --ctstate NEW -m statistic --mode nth --every 2 --packet 1 -j ACCEPT
/usr/sbin/iptables -t mangle -A PREROUTING -j DEF_POL
/usr/sbin/iptables -t nat -A POSTROUTING -m comment --comment 'snat outbound eth0' -o eth0 -s 192.168.0.0/16 -m mark --mark 101 -j SNAT --to-source 192.168.178.95
/usr/sbin/iptables -t nat -A POSTROUTING -m comment --comment 'snat outbound wlan0' -o wlan0 -s 192.168.0.0/16 -m mark --mark 102 -j SNAT --to-source 192.168.1.95
/usr/sbin/ip route flush cache

(this script was made by fukawi2, I don't know how to use iptables) but I have no Internet connection...


output of iptables -t mangle -nvL


Chain PREROUTING (policy ACCEPT 1254K packets, 1519M bytes)
pkts bytes target prot opt in out source destination
1278K 1535M CONNMARK all -- * * 0.0.0.0/0 0.0.0.0/0 CONNMARK restore
21532 15M ACCEPT all -- * * 0.0.0.0/0 0.0.0.0/0 /* this stream is already marked; escape early */ mark match ! 0x0
582 72579 MARK-gw1 all -- eth0 * 0.0.0.0/0 0.0.0.0/0 /* prevent asynchronous routing */ ctstate NEW
2376 696K MARK-gw2 all -- wlan0 * 0.0.0.0/0 0.0.0.0/0 /* prevent asynchronous routing */ ctstate NEW
1257K 1520M DEF_POL all -- * * 0.0.0.0/0 0.0.0.0/0

Chain INPUT (policy ACCEPT 1276K packets, 1535M bytes)
pkts bytes target prot opt in out source destination

Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
pkts bytes target prot opt in out source destination

Chain OUTPUT (policy ACCEPT 870K packets, 97M bytes)
pkts bytes target prot opt in out source destination

Chain POSTROUTING (policy ACCEPT 870K packets, 97M bytes)
pkts bytes target prot opt in out source destination

Chain DEF_POL (1 references)
pkts bytes target prot opt in out source destination
1236K 1517M CONNMARK tcp -- * * 0.0.0.0/0 0.0.0.0/0 /* default balancing */ ctstate RELATED,ESTABLISHED CONNMARK restore
15163 2041K CONNMARK udp -- * * 0.0.0.0/0 0.0.0.0/0 /* default balancing */ ctstate RELATED,ESTABLISHED CONNMARK restore
555 33176 MARK-gw1 tcp -- * * 0.0.0.0/0 0.0.0.0/0 /* balance gw1 tcp */ ctstate NEW statistic mode nth every 2
555 33176 ACCEPT tcp -- * * 0.0.0.0/0 0.0.0.0/0 /* balance gw1 tcp */ ctstate NEW statistic mode nth every 2
277 16516 MARK-gw2 tcp -- * * 0.0.0.0/0 0.0.0.0/0 /* balance gw2 tcp */ ctstate NEW statistic mode nth every 2 packet 1
277 16516 ACCEPT tcp -- * * 0.0.0.0/0 0.0.0.0/0 /* balance gw2 tcp */ ctstate NEW statistic mode nth every 2 packet 1
1442 384K MARK-gw1 udp -- * * 0.0.0.0/0 0.0.0.0/0 /* balance gw1 udp */ ctstate NEW statistic mode nth every 2
1442 384K ACCEPT udp -- * * 0.0.0.0/0 0.0.0.0/0 /* balance gw1 udp */ ctstate NEW statistic mode nth every 2
720 189K MARK-gw2 udp -- * * 0.0.0.0/0 0.0.0.0/0 /* balance gw2 udp */ ctstate NEW statistic mode nth every 2 packet 1
720 189K ACCEPT udp -- * * 0.0.0.0/0 0.0.0.0/0 /* balance gw2 udp */ ctstate NEW statistic mode nth every 2 packet 1

Chain MARK-gw1 (3 references)
pkts bytes target prot opt in out source destination
2579 490K MARK all -- * * 0.0.0.0/0 0.0.0.0/0 /* send via 192.168.178.1 */ MARK set 0x65
2579 490K CONNMARK all -- * * 0.0.0.0/0 0.0.0.0/0 CONNMARK save
2579 490K RETURN all -- * * 0.0.0.0/0 0.0.0.0/0

Chain MARK-gw2 (3 references)
pkts bytes target prot opt in out source destination
3373 901K MARK all -- * * 0.0.0.0/0 0.0.0.0/0 /* send via 192.168.1.1 */ MARK set 0x66
3373 901K CONNMARK all -- * * 0.0.0.0/0 0.0.0.0/0 CONNMARK save
3373 901K RETURN all -- * * 0.0.0.0/0 0.0.0.0/0

Answer



Unless you can somehow split up the traffic based on their local parameters (like LAN IP), using this solution you will end up having a lot of random errors because a lot of sites don't allow you to use the same session from radically different IP addresses, not to mention other protocols like FTP, DNS, etc.


If you really want to do this, you will need to rent a (virtual) server with at least 2 IP addresses and build a VPN on each of your connections, then set up an OSPF load balancing to utilize both connections equally. Your server will need to have at least the double of your two connections' speed together.


In summary: without network support failover works well enough, load balancing however is going to be a constant pain.


Update: What you need to do:



  1. Set up the server and make sure your local machine sees the two server IP's through different connections.

  2. Start two OpenVPN servers on the server, listening on each of the addresses.

  3. Start two OpenVPN clients on the client.

  4. Install Quagga on both the server and the client.

  5. Make sure the server and the client see each other through the OpenVPN without advertising any routes yet.

  6. Set up routing advertisement on the server so the default route (0.0.0.0/0) gets advertised over OSPF one link to the client via redistributing static routes. (This is hard.)

  7. Add the second link as a backup link over OSPF.

  8. Change the configuration so the two links are used in load balancing modes.


OSPF is a whole new world, it's an integral part of how the internet out there works. If you really want to do this, I recommend you give yourself time and read some books as it is way out of scope for this description. I've done this once and I might get back to writing a tutorial on this, but it will take considerable time so I'll make no promises.


open program instead system properties - windows 7


I want to open another program (like everest) to show system information instead the default windows 7 system information window when right-clicking on computer


enter image description here


Is there a way to replace the action on the "Properties Item" on the context menu on Windows 7?



Answer



Add A Context Menu Entry... Search On Google How to Add Context Menu Entry in Windows OS


ubuntu - Two routers with NAT in series, how to forward a port?


First of all I am a newbie at networking.


I have 2 PCs in two different networks. I'm trying to establish a connection between them.



  • First I obtained public IP of PC1 network: wget http://ipinfo.io/ip -qO –. The result was a.b.c.d.

  • On PC1 I use netcat to listen on a port nc -l -v 5555.

  • On PC2 I try to connect with nc a.b.c.d 5555. The result is I cannot connect.


I have no firewall and port forwarding is enabled in my router configuration:


router configuration


I made another test with a dedicated website:


testing the port


What did I do wrong here?




Update 1.


It was pointed out in comments/discussion that there is probably another router that does NAT (network address translation). I was asked to check the WAN IP address of my router. Here's the status:


WAN status of the router


The IP is different than the public IP I have discovered earlier. What to do now?




Update 2.


I managed to get to the other (outer) router config. This one has proper public IP on its WAN interface (a.b.c.d). I added a port forwarding rule. It points to my (inner) router local IP (192.168.9.1).


port forwarding on outermost router


Still my connection with nc doesn't work. What is wrong?



Answer



When your router does NAT, it has different IPs on its WAN and LAN interfaces. The same applies to the outer router in your setup. It looks like this (all the numbers are actual IPs taken from your screenshots):


Internet
|
WAN IP: a.b.c.d
outer router
LAN IP: 192.168.1.254
|
WAN IP: 192.168.1.100
inner router
LAN IP: 192.168.9.1
|
PC1 with IP 192.168.9.100

Your inner router is seen as 192.168.9.1 by your PC1 but the outer router can reach the inner one only by 192.168.1.100 address.


Solution: reconfigure the outer router to forward the port to 192.168.1.100 (not 192.168.9.1). Port forwarding on the inner router seems to be OK.




There is also an improvement you can make. It is common that home router offers dynamic IP addresses via DHCP and the pool starts with 192.168.???.100 (it can be changed, this is just a common default value). IP addresses of your PC1 and inner router (its WAN interface) end with 100. I think they were obtained via DHCP from respective dynamic pools. Your screenshot (update 1) tells this without doubt: "Dynamic IP".


With dynamic IPs it is possible any of these addresses will change in the future without any warning. In that case your port forwarding rule (one or the other, or both) will need to be adjusted to point to the new address.


To avoid this you should assign static IP to your inner router WAN interface (you should be able to do it in the outer router config, then reboot the inner one) and to your PC1 (in the inner router config, then reboot PC1). The setup may look like this (example):


Internet
|
WAN IP: a.b.c.d
outer router
LAN IP: 192.168.1.254
|
WAN IP: 192.168.1.5 (static, cannot change by itself)
inner router
LAN IP: 192.168.9.1
|
PC1 with IP 192.168.9.2 (static, cannot change by itself)

If you decide to set static addresses then you should reconfigure port forwarding rules accordingly. You may stick to your current settings, just keep in mind that your forwarding rules will not work if any dynamic address changes.


Where does Skype save my contact&#39;s avatars in Linux?

I'm using Skype on Linux. Where can I find images cached by skype of my contact's avatars? Answer I wanted to get those Skype avat...