Thursday, January 16, 2020

hard drive - Leaving bad sectors in unformatted partition?

Laptop was acting really weird, and copy and seek times were really slow, so I decided to scan the hard drive surface. I have a couple hundred bad sectors all clustered up in last couple of gigabytes on the hard drive. If I leave that part out unformatted, will it work right?


edit: This is the situation after testing. There is visible chaos at the end. All Sentinel or HDD Regenerator tests and repairs freeze when processes reaches 99%. It found additional 1 bad sector in the middle and a weird darker green pattern at the upper part of the image :)


Chkdsk with /f or /r also freezes at 99%. Done full windows format. People say that it should remap the bad sectors, but I'm not sure it did here any good.I will just try to make a 100 GB partition for system, and see how it works.


disk surface map

Tuesday, January 14, 2020

worksheet function - Multiple date formats in single column in excel


I have a csv file with a date column with dates in various forms as follows:


dd-mm-yyyy


yyyy-mm-dd


yyyy-mm


yyyy


This irregular data is in a single columns.


How do I convert all of them to the dd-mm-yyyy and extract the year from them using excel formula? The desired output is as follows:


Input       Output
25-03-1954 25-03-1954
22-09-1987 22-09-1987
1990-01-25 25-01-1990
1968-11-15 15-11-1968
1919-01 01-01-1919
1873-02 01-02-1873
1945 01-01-1945
1933 01-01-1933

Answer



If all that you really need is the Year, then use @robinCTS formula.


IF you want the result to be "real Excel Dates" and



  • if your data is TEXT and not real dates,

  • and if your regional date settings are DMY,

  • and the column is formatted as dd-mm-yyyy


then you could use this formula:


=IFERROR(IFERROR(IFERROR(DATEVALUE(A2),DATEVALUE(A2&"-01")),DATEVALUE(A2&"-01-01")),"illegal date format")

Note that dates prior to 1900 cannot be real dates in Excel, but could be represented as TEXT strings. I will leave it to you to tweak the formula.


If your output needs to be internationally aware to countries that have other date formats, then a VBA solution might be best. If that is not possible, helper columns to split the data and then reassemble appropriately, or a very complex formula to do the same, could be used.


Note that this UDF will output either the actual date, or just the year, depending on the second optional argument.


Option Explicit
Function ConvertToDate(S As String, Optional Yr As Boolean = False) As Variant
Dim V
Dim dtTemp As Date
V = Split(S, "-")
Select Case UBound(V)
Case 0
dtTemp = DateSerial(V(0), 1, 1)
Case 1
dtTemp = DateSerial(V(0), V(1), 1)
Case 2
If Len(V(0)) = 4 Then
dtTemp = CDate(S)
Else
dtTemp = DateSerial(V(2), V(1), V(0))
End If
End Select
If Yr = True Then
ConvertToDate = Year(dtTemp)
Else
If Year(dtTemp) < 1900 Then
ConvertToDate = Format(dtTemp, "dd-mm-yyyy")
Else
ConvertToDate = dtTemp
End If
End If
End Function

Both methods look at the first segment, and assume it is a year if LEN > 4, and then look at how many segments to decide whether to append the necessary -01's


The VBA solution will output dates prior to 1900 as a text string.


hard drive - BitLocker in Windows 7 Ultimate decryption of external HDD

I have locked my external hard disc using BitLocker. After formatting my computer I have lost all keys to open my external hard disc. Is there any way to unlock the external drive.

Display on TV using HDMI on laptop and TV

What settings on laptop are needed to get connection from Acer Travelmate 5730G hdmi port to hdmi tv to work. PC monitor works well with the laptop, but no luck with HDMI

microsoft excel 2007 - How to combine values from multiple rows into a single row

I have an Excel 2007 spreadsheet with 2250 rows and 19 columns. In these rows, I may have two rows of duplicate customer information that need to be combined, but only if the cell above is empty. I may also have rows of customer data that are not in need of combining. A unique customer member number can be used to identify the rows that need to be combined together. I'm struggling on developing the right VBA script to combine the unique customer data into the one row (on top) and delete the row that is remaining after combining. Is anyone willing to assist? It will save me hours/days of hand combining these rows and we are in the middle of a time sensitive audit.


Sample of our data:



MEMBER FIRST NAME MEMBER LAST NAME MEMBER # MVP SYSTEM ENTRY DATE ENROLL DATE MVP POINTS DRAWING ENTRIES ENROLL FORM? POINTS CORRECT? POINTS MISSED FINAL POINTS DRAWING ENTRIES SP Talon # WP Talon # BD DEPT EMPLOYEE NOTES DLR
Gene S 550061 3/2/2013 0 0 0 #N/A
Gene S 550061 3/2/2013 1539 137 MC MJ SP
Steve G 550087 3/2/2013 30019 1588 PA NR WP
Curtis S 550128 4/24/2013 5 0 5 #N/A
Curt S 550128 4/24/2013 358 47 MC MJ SP

Edit (not from OP) to add pipe/paragraph delimited version with underlines for spaces in headings:


MEMBER_FIRST_NAME|MEMBER_LAST_NAME|MEMBER_#|MVP_SYSTEM_ENTRY_DATE|ENROLL_DATE|MVP_POINTS|DRAWING_ENTRIES|ENROLL_FORM?|POINTS_CORRECT?|POINTS_MISSED|FINAL_POINTS|DRAWING_ENTRIES|SP_Talon_#|WP_Talon_#|BD|DEPT|EMPLOYEE|NOTES|DLR
Gene|S|550061|03/02/2013||0|0||||0|#N/A|||||||
Gene|S|550061||03/02/2013||||||||1539|137||MC|MJ||SP
Steve|G|550087||03/02/2013||||||||30019|1588||PA|NR||WP
Curtis|S|550128|4/24/2013||5|0||||5|#N/A|||||||
Curt|S|550128||4/24/2013||||||||358|47||MC|MJ||SP

windows 10 - I get the error: "Reboot and Select proper Boot device"



After I got a new and bigger SSD, I wanted to install Windows 10 on it. For some reason BIOS did not list my bootable USB device, with the Windows 10 installation. So I connected it thorugh SATA instead, and now it would let me install Windows 10. Problem is, everytime I disconnect the HDD where the Windows 10 installation is located, I get the error: "Reboot and Select proper Boot device" during boot. When I connect the HDD, it seems to boot from the installation HDD, and let me choose to open into Windows 10 (on the SSD). I can then use Windows 10 normally.



Som other info:



When the installation HDD is disconnected and I go into BIOS, the SSD is the only thing listed under boot devices. If I choose the SSD manually from BIOS, I get the same error message.



At first under the Windows 10 installation, I coulnd't install on the SSD because of it being a GPT-partition. I used Diskpart and then installed Windows 10.




I have tried to set the SSD as "active" with Diskpart.



BIOS Mode



MSInfo32 shows: Legacy



Title shown in BIOS menu: UEFI BIOS Utility - EZ Mode



BIOS when old and new SSD is connected. The old SSD (with working Windows 10) has the UEFI label.



Answer



So I found a USB drive that worked. I'm not sure what went wrong, when trying to connect. Now I got a fully functional Windows 10.


Monday, January 13, 2020

Our WSUS accidentally had Windows Insider updates turned on. How can I remove the 1909 update from my Windows Update screen without installing it?



There was a misconfiguration in my company WSUS and Windows Insider updates were accidentally included (our sysadmin checked the box for all Windows components and apparently Windows Insider was a part of that). I'm the only user with a Windows 10 machine (small shop of half a dozen people), and as such, my Windows Update recommends I install the 1909 feature update. Note that this machine is not enrolled in Windows Insider, has never been enrolled in Windows Insider and is not planned to ever be enrolled in Windows Insider. I'm not the sysadmin. Note that we use our WSUS only as a database of available updates, not to also distribute the updates themselves. We download the Windows updates themselves from the official Microsoft servers.



Our sysadmin has unchecked the Windows Insider box, but I still got that "Evaluation version of Windows Insider component update to version 1909 x64" update in my Windows update list. I've tried hiding the update through that one troubleshooting thing you can download, I've tried restarting the Windows Update service and I've tried deleting my SoftwareDistribution folder, but I can't figure out how to make this update go away. I've clicked the option to pause the updates for 7 days, but I don't know what else to do. I really don't want to accidentally install this update and then end up with an evaluation edition of Windows 10 1909 meant for betatesters.


Answer



I mentioned in my question that I paused updates for 7 days. I just resumed the looking for updates, and it checked for updates again and didn't find the Windows Insider update again (this was after our Sysadmin disabled the Windows insider box).



So I managed to solve my problem (how to remove the 1909 update from Windows 10 Windows Update settings screen without installing it) by first pausing Windows Updates for 7 days and then resuming the Windows updates immediately afterwards. This triggers a new search for Windows updates and indeed uses the new WSUS configuration for updates. Because at this point the Windows Insider updates were turned off, it didn't recommend it again during this check.


windows xp - Install XP(SP3) on laptop with SATA drive?


For testing purposes, I need to wipe out W7 from an Aspire 3810T laptop and install XP(SP3) on it.


Tried three different CD's, but they all failed, possibly because the drive is SATA. In the BIOS, changed AHCI to IDE, but it didn't work.


Next, downloaded the latest AHCI Intel SATA AHCI Driver (8.8.0.1009) from Acer's site, put the files on a USB drive, hit F6 when prompted to add drivers, but XP simply goes ahead without reading the USB drive.


Next, I figured maybe upgrading the BIOS would solve the issue, so ran Unetbootin to install FreeDOS on a USB key, downloaded and copied BIOS upgrade 1.28 onto the USB key, rebooted on the USB key, typed C: to switch to the USB key, hit F.BAT which calls "fla JM31.128", but got a crash:


DOS/4GW Professional error (2001): exception 0EH

Does someone know how to install XP on a laptop with SATA drive?


Thank you.


Answer



You can't load drivers into xp via a USB key - you have to use a floppy drive, or slipstream it with nlite.


windows 7 - Hard drive showing 333 MB of used space even though there are no files?

I've been using an external hard drive for quite some time, and recently I've upgraded to an internal drive and therefore moved all of my files from the external hard drive to the internal one.


Now my external hard drive is (obviously) empty. But at the same time it's not.


For some reason Windows and also Linux still show around 333-336 MB of used space, even though the drive is completely empty.


Yes, I am viewing hidden files. Yes, I am also viewing protected system files.
The only 2 folders remaining were a Recycle Bin folder, which is empty, and the System Volume Information folder.


So I went ahead and booted into Ubuntu, deleted both folders (which were only 1 MB in total), pressed CTRL+H in the file manager to view hidden files and yes, the drive is now really empty (some weird Trash folder appeared which I can't delete but its less than a KB big).


Yet Windows and GParted still say that 333 MB is in use.


How can that be?


The external HDD is made by Western Digitals, has 500 GB total space, and the partition is 500 GB big (NTFS).


Here's a screenshot:


enter image description here


In Windows 7:


enter image description here

Windows 7 Icon Placement

I have just moved to Windows 7 and I am rather bothered by the icon placement in the details view.


In every version of windows before 7 the Icon followed the name of the file. However, someone at Microsoft decided that it would be a better idea to place the icon at the beginning of the details view row.


I prefer to have size as my first column and I am not alone. When I move it there the Icon does not move with the name like it used to.


I am wondering if anyone knows of a way to change the icon position?


Here is a picture of what I am talking about:


enter image description here

macos - Disable clamshell mode in OS X Mountain Lion

I am running OS X 10.8.5 with an external monitor, and whenever I close the lid of my laptop it automatically goes into clamshell mode so that all the screen contents switch to the external monitor.


When I was running OS X 10.6.8, the machine will go into sleep when I close the lid so that the external monitor goes blank.


What setting(s) should I change in 10.8.5 to bring back the 'sleep' behavior?

Sunday, January 12, 2020

Understanding micro SD cards for camera


I am looking for a micro SD card for my point n shoot camera. I just know that better SD cards have better write/read speed.


I have following questions:



  • What do Class-10 and SDHC specify?

  • In the picture below, Samsung mentions that the card can be used for Digital Cameras but Scandisk does not say something like that. Does that mean, an SD card may or may not support a Digital Camera?

  • I understand that hardware recommendations cannot be asked but I am just wondering where "Toshiba Exceria" card stands in comparison to other cards in the picture below in terms of performance.


enter image description here


Answer



The SDHC is the format of SD interface (like SD v2.0). It's capable to provide capacities 2-32GB. For higher capacities there is the SDXC (up to 512 GB). Check what format your camera actually supports.


The Class 10 says that the guaranteed speed is 10MB/s or more. In general it should be sufficient for FullHD 1080p. The Class 10 cards are also marked as UHS Class 1.


windows 7 - How do I write a batch script that iterates through all png files in all subfolders and does an action?



I'm looking to build a small batch script that executes the command line of pngout.exe



So far I've got only this down




for %i in (*.png) do "g:\myfiles\_pngout.exe" "%i" /s0 /c6


However, for that to work I have to manually go to each folder where the pngs are and open up a cmd window from Win7 then copy and paste that line.



What I want is for that line to work say in C:\MyPNGs and it's sub-folders, like C:\MyPNGs\Avatars etc., it should iterate through all pngs and every time execute that "g:\myfiles\_pngout.exe" "%i" /s0 /c6



Any ideas?


Answer




You can use the following command from a dosprompt:



for /r %f in (*.png) do _pngout.exe "%f"


or the following inside a batch file:



for /r %%f in (*.png) do _pngout.exe "%%f"



For /r also has support to give a start directory. Otherwise it'll use the current directory and get every file in all subdirectories that match your filemask.


windows - Synaptics touchpad stops working randomly

I have two laptops. One dell Vostro and other Vaio Z. Both have Synaptics (Yes, I have checked, and the original drivers were from Synaptics as well). On both laptops, the touchpad scrolling stops working at some arbitrary time and nothing seems to solve it except a reboot. Sometimes, it randomly starts working again. I have downloaded all latest drivers from OEM.



Interestingly, when I run a program as Administrator, scrolling works in that window only.




This problem is very odd. It happens without any reason and I've not been able to find a fix for more than a year. I have seen some unusual suggestions on forums (e.g., to "restore windows to a previous working state") but never any fix that solves this issue properly. I have tried installing latest drivers and I DO NOT want to restore windows to a previous working configuration.



OS:
Windows 7 64 bit Professional (Sony Vaio Z - VPCZ128GG)
Windows 7 32 bit Professional (Dell)



EDIT: Temporary solution is to uninstall the synaptics driver and let Windows 7 use its default built in one. However, I really prefer the Synaptic driver because it activates the scroll button rather than the mouse wheel (useful in some apps)

Saturday, January 11, 2020

Windows "not genuine" after entering several commands

After entering these commands:
bootrec.exe /FixMbr
bootrec.exe/FixBoot
bootrec.exe/RebuildBCD
bcdedit /export C:\BCD_Backup
c:
cd boot attrib bcd -s -h -r
bootrec /RebuildBcd


My windows claims to be "not genuine" and I have 30 days to fix it... Does anyone know what I did to mess it up? and how I can reverse it?


Thank you.

macos - Mac: what permissions are granted for "allow the apps below to control your computer"?

I want to use an app from the mac app store (window tidy) but it wants me to give it control "over the computer". This setting is found under security & privacy > accessibility


This seems like a very big umbrella permission, and I can't seem to find out what this actually means in terms of what permissions it grants to apps.


What is the worst that can happen? Can it read my files? Can it make network calls to transfer my files, encrypted files, etc? Can it access contacts, and send emails as me?


I've looked online and this seems quite hard to answer. Does anyone know?


Thanks...


Update based on @teppic's comment below:


$ codesign -d --entitlements :- /Applications/Window\ Tidy.app
Executable=/Applications/Window Tidy.app/Contents/MacOS/Window Tidy




com.apple.application-identifier
34U5SFK3WS.com.lightpillar.Window-Tidy
com.apple.developer.team-identifier
34U5SFK3WS


Update 2


Continuing my curiosity, I installed the network monitoring tool Little Snitch to block and monitor outgoing communications. And in less than 1.5 hrs, Window Tidy (which is a simple app meant to resize windows) has reached out to connect over the network 3564 times. Definitely seems dangerous to have this app have access to read my files and control other apps...


enter image description here

windows 7 - Automatically extract and rename extracted file according to archive's name

I have a bunch of zip files in a folder. Each zip file has a file in it named exp_1.txt. I would like to unzip each zip file and rename the extracted file from each zip file to what the zip file was named.



The zip files names don't follow any pattern or date structure, but are all different. I have figured out how to get the exp_1.txt file extracted into the same directory as the zip file, but can't figure out the renaming of exp_1.txt to match what the zip file it was extracted from is named.



Once again in fewer words: from TuesdayReport.zip I want to extract the only file exp_1.txt and rename it to TuesdayReport.txt in the same directory as TuesdayReport.zip.




Currently I'm using 7z x to extract the file to the same directory the zip file is located in. I would prefer to be able to run this from a batch file.

How to remap keys under Linux for a specific keyboard only


I've recently bought a Unicomp keyboard that comes with swapped right-alt and Windows keys. The keyboard identifies like this on lsusb:


Bus 003 Device 002: ID 17f6:0822 Unicomp, Inc

Is there a way to have the kernel (i.e. not xmodmap-based) swap the right-alt and windows keys so every application sees them in the swapped places even if they get raw keyboard input (swapping stuff with xmodmap won't do that)? Is there a way to have that only for this one keyboard?


Answer



Yes, it's possible using XKB. Unlike xmodmap, XKB can remap your keys for individual devices.


Note: Make sure you have xkbcomp > 1.2.0


First list your devices with:


xinput list


You'll get something like this:


⎡ Virtual core pointer                      id=2    [master pointer  (3)]
⎜ ↳ Virtual core XTEST pointer id=4 [slave pointer (2)]
⎜ ↳ Wacom Bamboo Pen Pen stylus id=11 [slave pointer (2)]
⎜ ↳ Wacom Bamboo Pen Finger touch id=12 [slave pointer (2)]
⎜ ↳ Logitech USB-PS/2 Optical Mouse id=13 [slave pointer (2)]
⎜ ↳ Wacom Bamboo Pen Pen eraser id=14 [slave pointer (2)]
⎜ ↳ Wacom Bamboo Pen Finger pad id=15 [slave pointer (2)]
⎜ ↳ GASIA USB KB V11 id=17 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Virtual core XTEST keyboard id=5 [slave keyboard (3)]
↳ Power Button id=6 [slave keyboard (3)]
↳ Power Button id=7 [slave keyboard (3)]
↳ G19 Gaming Keyboard id=8 [slave keyboard (3)]
↳ G19 Gaming Keyboard id=9 [slave keyboard (3)]
↳ Logitech G19 Gaming Keyboard id=10 [slave keyboard (3)]
↳ GASIA USB KB V11 id=16 [slave keyboard (3)]

Identify the string of your device and edit the following shell script, changing the sed line with one that fits your device's name. Then change the keys you need remapped.


Example: Load xev and press a key you want to remap. Suppose you find out it's keycode 84. Lookup 84 in https://gist.github.com/zoqaeski/3880640. The key name there is . Then lookup the key you want it replaced by (in the same link, farther below) and copy what's inside the brackets. Repeat the process for all the keys you want.


remote_id=$(
xinput list |
sed -n 's/.*GASIA.*id=\([0-9]*\).*keyboard.*/\1/p'
)
[ "$remote_id" ] || exit
# remap the following keys, only for my custom vintage atari joystick connected
# through an old USB keyboard:
#
# keypad 5 -> keypad 6
# . -> keypad 2
# [ -> keypad 8
# left shift -> left control
mkdir -p /tmp/xkb/symbols
# This is a name for the file, it could be anything you
# want. For us, we'll name it "custom". This is important
# later.
#
# The KP_* come from /usr/include/X11/keysymdef.h
# Also note the name, "remote" is there in the stanza
# definition.
cat >/tmp/xkb/symbols/custom <<\EOF
xkb_symbols "remote" {
key { [ KP_Right, KP_6, U2192, U21D2 ] };
key { [ KP_Down, KP_2, U2193, U21D3 ] };
key { [ KP_Up, KP_8, U2191, U21D1 ] };
key { [ Control_L ] };
};
EOF
# (1) We list our current definition
# (2) Modify it to have a keyboard mapping using the name
# we used above, in this case it's the "remote" definition
# described in the file named "custom" which we specify in
# this world as "custom(remote)".
# (3) Now we take that as input back into our definition of the
# keyboard. This includes the file we just made, read in last,
# so as to override any prior definitions. Importantly we
# need to include the directory of the place we placed the file
# to be considered when reading things in.
#
# Also notice that we aren't including exactly the
# directory we specified above. In this case, it will be looking
# for a directory structure similar to /usr/share/X11/xkb
#
# What we provided was a "symbols" file. That's why above we put
# the file into a "symbols" directory, which is not being included
# below.
setxkbmap -device $remote_id -print \
| sed 's/\(xkb_symbols.*\)"/\1+custom(remote)"/' \
| xkbcomp -I/tmp/xkb -i $remote_id -synch - $DISPLAY 2>/dev/null

Then source it (you can add it to your .xinitrc). All done! Now pressing the keys should generate the desired output, only for the device you specified.


Edit: Recently, I've noticed that, for some reason, the new configuration isn't applied immediately. You must first press a key on your other keyboard, then test the configured keys on your modified keyboard. I don't know why this happens, maybe some sort of cache.


How to Restart Windows Update Service in Windows 7?


I'm running into an issue with Windows Update on Windows 7 Professional. I am totally up to date in Windows Updates as of last week, but discovered this issue [today] during my Sunday morning PC maintenance ritual. In CONTROL PANEL -> SYSTEM & SECURITY -> Windows Update, when I select "Check for Updates", I get a pop-up stating:


"Windows Update cannot currently check for updates, because the service is not running. You may need to restart your computer."


I've re-started several times, checked that the service hadn't been disabled at start up, and I've googled extensively on the topic - but have come up with nothing. I know there must be some way to start the service from the cmd line, and I would like to know how to get the service to start at boot.


Please let me know if I have left any details out that may aid in formulating a response. Any of the community's excellent insights would be greatly appreciated!


Answer



You can try stopping and restarting Windows Update Service (wuauserv). Open a command line window (run as administrator) and enter the following lines:


net stop wuauserv
regsvr32 %windir%\system32\wups2.dll
net start wuauserv

If that does not help, try Microsoft's Fix It service to reset your Windows Update Components: How do I reset Windows Update components?


Deleting (Erasing) all Data from Failed SanDisk MicroSD Card

I've had two 32GB SanDisk MicroSD cards go bad recently. One I was able to temporarily revive using the kind advice offered in this thread: Recover Data from Card that cannot be read




When I insert the other into a reader, it registers as 30.6MB (that's MB, not GB).



I've tried all sorts of software and other techniques to revive this card and retrieve the important data off of it (including FindAndMount and TestDisk). Nothing has worked.



So I'm thinking of returning the card for a refund.



But first, I would like to make it unreadable by someone more skilled than myself. Is there any way to do this, given that I cannot even format the card or get it to be recognized as more than 30.6MB?



I am looking for a method that does not entail the kind of obvious physical destruction that would jeopardize obtaining a refund from the retailer. If Costco (where the card was purchased) accepts physically destroyed cards for return, then physical destruction is acceptable (but please have knowledge that they do).




Given two failures, I don't really want to send the card to SanDisk for replacement, because I no longer trust the reliability of their products.

Truecrypt container with NTFS on a Truecrypt disk unmountable

I have following setup:
OS Ubuntu/Gnome,
1 TB external drive, created and encrypted (whole disk encryption) on Windows7.
On this encrypted partition I have a 80 GB Truecrypt Container.


My system froze when it was copying data to this mounted, encrypted container.
Now I am able to mount and access data on the encrypted drive, I see the encrypted container but I can't mount it, nor repair it in any way.
When trying to mount it with TC I get:
"$MFTMirr does not match $MFT (record 0).
Failed to mount '/dev/mapper/truecrypt9': Input/output error"
I cannot do any ntfsfix on since it is not a real device to get access to ...

partitioning - Clone Hard Disk except got One Partition

I would like to replace a hard disk in my desktop with a smaller SSD. This hard disk has the following partition setup:



  • Linux ext4 partition (and related swap partitions)

  • Windows 7 NTFS partition

  • miscellaneous partition for file storage


I have tried manually copying partitions to the SSD and recreating the boot sector, but this has not worked well.


I would like to make a near identical copy of the hard disk onto the SSD minus the miscellaneous partition -- this way, all of the data will fit on the smaller SSD.


Is it possible for me to clone the hard disk, including the bootloader, to the new SSD EXCEPT for this "miscellaneous" partition?

Friday, January 10, 2020

autohotkey - How to remap Win+Tab with Alt+Tab in Windows 7?

Is there a way to replace the Win+Tab key combination with Alt+Tab in Windows 7?


I'd be interested in a way to do so without Autohotkey, but if Autohotkey is the only answer please provide the script.


I would like to replace Win+Shift+Tab with Alt+Shift+Tab as well.

search - What's a cross-platform solution for tagging files on a USB drive?

I'd like to add custom search tags for Spotlight, Windows Search, and Linux Beagle, all on the same NTFS-formatted USB drive. What's the closest software solution to this?

disk space - Linux utility for finding the largest files/directories





I'm looking for a program to show me which files/directories occupy the most space, something like:




74% music
\- 60% music1
\- 14% music2
12% code
13% other


I know that it's possible in KDE3, but I'd rather not do that - KDE4 or command line are preferred.


Answer




To find the largest 10 files (linux/bash):



find . -type f -print0 | xargs -0 du | sort -n | tail -10 | cut -f2 | xargs -I{} du -sh {}



To find the largest 10 directories:



find . -type d -print0 | xargs -0 du | sort -n | tail -10 | cut -f2 | xargs -I{} du -sh {}



Only difference is -type {d:f}.




Handles files with spaces in the names, and produces human readable file sizes in the output. Largest file listed last. The argument to tail is the number of results you see (here the 10 largest).



There are two techniques used to handle spaces in file names. The find -print0 | xargs -0 uses null delimiters instead of spaces, and the second xargs -I{} uses newlines instead of spaces to terminate input items.



example:



$ find . -type f -print0 | xargs -0 du | sort -n | tail -10 | cut -f2 | xargs -I{} du -sh {}

76M ./snapshots/projects/weekly.1/onthisday/onthisday.tar.gz
76M ./snapshots/projects/weekly.2/onthisday/onthisday.tar.gz

76M ./snapshots/projects/weekly.3/onthisday/onthisday.tar.gz
76M ./tmp/projects/onthisday/onthisday.tar.gz
114M ./Dropbox/snapshots/weekly.tgz
114M ./Dropbox/snapshots/daily.tgz
114M ./Dropbox/snapshots/monthly.tgz
117M ./Calibre Library/Robert Martin/cc.mobi
159M ./.local/share/Trash/files/funky chicken.mpg
346M ./Downloads/The Walking Dead S02E02 ... (dutch subs nl).avi

Thursday, January 9, 2020

linux - Why am I getting a disk boot failure when I try to install Ubuntu?

I'm encountering boot failure while trying to install a Linux distro from a CD. I'm using an older PC; here are its specs:


HP Pavilion 2.66GHz, 512MB RAM with a BIOS revision of 6/30/2003


I reclaimed an older drive (Seagate ST340810A) that seems to be working, as it's recognized in the BIOS (auto-detected).


I downloaded a mini.iso of Ubuntu 10.10 that I want to install, and burned the image to a CD for install.


My boot sequence is: First Boot Device [CDROM]. I disabled devices 2-4 so I can just force it to read first from the CD-ROM.


This old PC also has a separate CD writer which is a Sec.Slave. The Sec.Master is the Toshiba DVD/ROM DSM-171 drive where I placed the burned Linux CD.


With these settings I cannot get it to boot. I get the message



"DISK BOOT FAILURE, INSERT SYSTEM DISK AND PRESS ENTER"



when I try

firefox - Mozilla Thunderbird HTTP Authentication

I set up Mozilla Thunderbird on Windows 7 Enterprise, and I set my main page to my own site. (Which requires HTTP/1.1 authentication).



Before I even have an HTTP authentication window (displayed for HTTP authentication in most browsers), it displays my custom 401 message set on the webserver.



Is there any Thunderbird plugin to fix this? or do I have to make do, or do I have to code an extra login form in PHP?



If I have to set up a PHP login form, how do I setup an HTTP Authentication form as a webpage?

How to disable Windows Defender via PowerShell on Windows 10 version 1903+?

So, I need to automatically disable Windows Defender for certain virtual machines via a PowerShell script. Previous to the May update, one could set the DisableAntiSpyware and DisableRoutinelyTakingAction in the registry and Defender was disabled.


Now with version 1903, this doesn't seem to work anymore. Even with disabling the Anti temper protection via registry and rebooting, I only get a permission denied when trying to set the two registry values.


Does anyone have ideas how I could solve this? I tried using the Invoke-CommandAs to do this as SYSTEM, however this didn't work either sadly.

Windows Boot Manager can't boot grubx64.efi

I tried adding grubx64.efi in the Windows Boot Manager using BCDEdit. However when I boot up my computer and try to start GRUB from Windows Boot Manager by clicking on the entry I created, I get:




File: \EFI\ubuntu\grubx64.efi




Status: 0xc000007b



Info: The application or operating system couldn't be loaded because a required file is missing or contains errors.




I know that the efi file works because I can boot GRUB up, from the same file, from the same location (the ESP partition) using an EFI shell, such as the one found in this answer: https://unix.stackexchange.com/a/63898/167564



Here's my bcdedit output:



Windows Boot Manager

--------------------
identifier {bootmgr}
device partition=\Device\HarddiskVolume2
path \EFI\Microsoft\Boot\bootmgfw.efi
description Windows Boot Manager
locale en-US
inherit {globalsettings}
flightsigning Yes
default {current}
resumeobject {4c60dca4-e732-11e5-be25-b3798e2bd780}

displayorder {current}
{4c60dcaf-e732-11e5-be25-b3798e2bd780}
toolsdisplayorder {memdiag}
timeout 10

Windows Boot Loader
-------------------
identifier {current}
device partition=C:
path \WINDOWS\system32\winload.efi

description Windows 10
locale en-US
inherit {bootloadersettings}
recoverysequence {4c60dca6-e732-11e5-be25-b3798e2bd780}
recoveryenabled Yes
isolatedcontext Yes
flightsigning Yes
allowedinmemorysettings 0x15000075
osdevice partition=C:
systemroot \WINDOWS

resumeobject {4c60dca4-e732-11e5-be25-b3798e2bd780}
nx OptIn
bootmenupolicy Standard

Real-mode Boot Sector
---------------------
identifier {4c60dcaf-e732-11e5-be25-b3798e2bd780}
device partition=\Device\HarddiskVolume2
path \EFI\ubuntu\grubx64.efi
description Grub Test

locale en-US
inherit {globalsettings}
flightsigning Yes
custom:23000003 {current}
custom:23000006 {4c60dca4-e732-11e5-be25-b3798e2bd780}
custom:24000001 {current}
{4c60dca8-e732-11e5-be25-b3798e2bd780}
custom:24000010 {memdiag}
custom:25000004 10



As you can see by the output, the last entry was the one I experimented trying to get Grub to work, the one that says "Real-mode Boot Sector". I created it by creating a copy of "{bootmgr}", and renaming it to "Grub Test", and changing the path to where grub was located. I saw this answer, and it says the correct entry is bootsector, so I went into regedit and changed it from "Windows Boot Manager" to "Real-mode Boot Sector", by changing values under BCD00000000 as explained in this post: Windows 8.1 UEFI x64 is not able to boot-up UEFI Images



I also tried changing it to:




  • 0x10100003 (Firmware Application)

  • 0x10100002 (Windows Boot Manager)

  • 0x10200003 (Windows Boot Loader)

  • 0x10400008 (Real-mode Boot Sector)


  • 0x20200008 (Inherited Settings)



However they all ended up with:




File: \EFI\ubuntu\grubx64.efi



Status: 0xc000007b




Info: The application or operating system couldn't be loaded because a required file is missing or contains errors.




Can I somehow make Windows Boot Manager be able to boot Grub? I searched all over the Internet and couldn't find anything of use to me, I'm kind of frustrated.



Also, secure boot is turned off.

Wednesday, January 8, 2020

Windows 7 is shutting down unexpectedly, according to the logs



Here's a message from my eventvwr EventLog (Windows Logs > System):



The previous system shutdown at 11:51:15 AM on ‎7/‎29/‎2009 was unexpected.



This is funny because I was wondering why the system shut down while I was playing Civilizations IV full screen. Now I know. It was unexpected.



Has anyone encountered and resolved this?



A little background:



I am running Windows 7 RC inside VMWare Fusion 2 (just updated a few months back) on a MacBook (Bitterly not Pro) aluminum-body. Windows 7 occasionally will shut down. This isn't a quick turn-off, it's a shutdown where all the programs are exited, the system waits until they quit (and Civ4 doesn't prompt me to save), it even installed Windows Updates before restarting. And yes it is restarting right after the shutdown. Because I run a game in full screen mode I do not notice any dialog with a countdown timer or anything like that that might be a warning.



As I have iStat on my dashboard widgets I can see about 8 temperature monitors. I have seen the CPU get up to 74C before, but during the shutdown, though it seemed hot to the touch (always is), it read 61C for the CPU, 60C for heatsink A, 50C for heatsink B and in the 30s-40s for the enclosure and harddrives. As I type this now, the temps are actually higher, so I don't think the temperature caused it.




I have at least six such events dating first from 5/17 which was a week after installing Windows 7.



I did find one information level warning from USER32 in the system log that says:



The process C:\Windows\system32\svchost.exe (DLAMBLIN-WIN7) has initiated the restart of
computer DLAMBLIN-WIN7 on behalf of user NT AUTHORITY\SYSTEM for the following reason:
Operating System: Recovery (Planned)
Reason Code: 0x80020002
Shutdown Type: restart

Comment:


And another 15 minutes before that from Windows Update:



Restart Required: To complete the installation of the following updates, 
the computer will be restarted within 15 minutes:
- Cumulative Security Update for Internet Explorer 8 for Windows 7 Release Candidate
for x64-based Systems (KB972260)



Which I think kind of explains it. Though I don't know why restarting after an update would create an error event of "shutdown was unexpected", isn't that pretty odd?



Now, how do I set it to never restart after an update unless I click something.



Application of solution:



As fretje reminded me, there's a couple of configurable settings for this, in windows 7 they're much in the same place as in Windows 2000 SP3 and XP SP1. Running gpedit.msc pops up a window that looks like:



gpedit.msc




Windows 7 has changed the order and added a couple of newer options I've italicized:




  1. Do not display 'Install Updates and Shut Down' in Shut Down Windows dialog box


    • Do not adjust default option to 'Install Updates and Shut Down' in Shut Down Windows dialog box

    • Enabling Windows Power Management to automatically wake up the system to install scheduled updates

    • Configure Automatic Updates


    • Specify intranet Microsoft update service location

    • Automatic Updates detection frequency

    • Allow non-administrators to receive update notifications

    • Turn on Software Notifications


  2. Allow Automatic Updates immediate installation


    • Turn on recommended updates via Automatic Updates

    • No auto-restart with logged-on users for scheduled Automatic Updates


    • Re-prompt for restart with scheduled installations.

    • Delay Restart for scheduled installations

    • Reschedule Automatic Updates scheduled installations

    • Enable Client Side targeting

    • Allow signed updates from an intranet Microsoft update service




Personally I chose to enable 9, 11, 12, and 13. 9 enables only those updates that do not have to restart Windows nor stop a service. Enabling 11 actually disables the auto-restart. 12 and 13 were enabled and set to their max values with the scroll wheel. 16 sounds good but won't affect users lacking their own update server.




Addendum



It's been pointed out that Home editions of Windows don't come with gpedit.msc, and you must therefore set things directly in the registry. There's probably more settings you could add besides NoAutoRebootWithLoggedOnUsers ... In fact I'm going to check that now. Okay in HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU add:




  1. AutoInstallMinorUpdates = 1


    • NoRebootWithLoggedOnUsers = 1

    • RebootRelaunchTimeout = 1440 (decimal)


    • RebootRelaunchTimeoutEnabled = 1 [I'm actually curious if that's what I wanted]

    • RebootWarningTimeout = 30 (decimal)

    • RebootWarningTimeoutEnabled = 1 [I think the above four don't happen due to #2]



Answer



Jeff actually blogged about this.



It's for Windows XP but I suppose this still works for Windows 7. It basically comes down to flipping a switch in the Local Group Policy Editor (gpedit.msc).


windows 7 - run as "NT AUTHORITYSYSTEM" is ideal for scheduled tasks?

I have a backup / autoupdate process for my software, and usually I create a new user for running it in task scheduler (most users don't have a password, and task scheduler needs it, don't know why).



Then I've seen that google chrome installs it's auto-update task to run as "NT AUTHORITY\SYSTEM", I've tested it and it works great with my programs too, and it looks more clean,



there are some hidden drawbacks here I'm not seeing?



Thanks!

Disable shortcut of translation in Google Chrome

Is it possible to disable right click + T, the shortcut for translation? Or is it possible to totally disable the Chrome translation function?

linux - cp: reading `filename': Input/output error WHY?

I wish to know what could be the possible cases for this error:




cp: reading `filename': Input/output error


I am getting this message when I am trying to copy a big file of around 50MB.

battery - Asus laptop won't turn on

I think I ran the battery too low (I have one power cord that I share between two computers and I was stupidly trying to use both machines at the same time and lost track of how long this one had been unplugged). This is an Asus X44H, and now it won't power on. I tried removing the battery and holding down the power button for several minutes, but when I put the battery back in, it didn't turn on; the only sign of power I get is that the green light next to the light bulb symbol is turned on. I've tried leaving the computer plugged in for three or four hours, but so far nothing happens other than this green light's staying on. Is leaving the machine plugged in, say, overnight likely to help? Or is there something else I can do that could get this to power on again? Thanks.

Windows 7: Desktop icons for new files are [sometimes] added in wrong position

I have 62 icons on my Windows 7 Desktop. (Only one monitor.) (Windows Classic theme.) I always enable "Auto arrange icons" and "Align icons to grid" (and never disable "Show desktop icons"). With Windows XP and prior, whenever I downloaded a file to the Desktop (using Firefox, with its default save-to location set to Desktop), Windows added the icon for the new file at the END of the Desktop icons: below the lowest icon in the right-most column of icons if possible, or else at the top of the next column. Now, Windows 7 adds the icon for the new file in the FIRST column of icons, second position (below Computer), and all the other icons get pushed down by 1 (with wrapping to the top of the next column). I didn't ask Windows to insert the icon near the top; I expect it to add it at the end, like before. What happened? How to fix it? (At times I think I triggered it by using "Show hidden files" and turning off "Hide protected operating system files".)


This is an OLD problem. (Maybe Vista did it too. I didn't notice.) I am disappointed that I never stumbled onto an answer. I am disappointed that I cannot FIND an answer. I found other posts of the question, but it was not phrased well, enabling answerers to misunderstand the question and post irrelevant answers.


Right now I cannot clarify which provocations cause the problem and which do not, because my Windows is, for the moment, doing the right thing. (Murphy's Law.) Some other provocations that I would test are: If I do "Save Page As..." or "Save Image As". If I download or save from a different browser. If I open an Explorer window, navigate to "Desktop", "%userprofile%\Desktop", or "C:\Users\Public\Desktop", and create a new file or folder. If I open a command prompt and type "md Desktop\x". If I save from a different app, like Notepad2 or WordPad.

Tuesday, January 7, 2020

USB-based AV application that restores compromised Windows files from CD/DVD?

I just tried a couple of rescue disks (AVG and Kaspersky), and I was wondering if someone knew of a solution that would work like this:





  • The AV solution boots from a USB key, and works entirely from RAM (where the latest virus DB is downloaded)

  • The user inserts his Windows CD/DVD in the drive

  • If any Windows file is compromised, the AV application fetches a clean version from the CD/DVD and restores it on the hard drive

  • optionally, any compromised drive/user-land application is quarantied, and it is up to the user to reinstall those after he successfully rebooted into a restored Windows setup



Have you heard of a solution like this? It seems silly to reinstall a whole Windows computer just because one or a few system files were compromised.



Thank you.

linux - iptables: Allow only HTTP access for web browsing

Have a linux box, want it locked down but just be able to surf internet on it. Why is this script blocking http too?




#!/bin/sh
#
#
iptables -F


#
#Set default policies for INPUT, FORWARD and OUTPUT chains
#
iptables -P INPUT DROP
iptables -P FORWARD DROP
iptables -P OUTPUT DROP

#
# Allow TCP connections on tcp port 80

#
iptables -A INPUT -i eth0 -p tcp --dport 80 -m state --state NEW,ESTABLISHED -j ACCEPT
iptables -A OUTPUT -o eth0 -p tcp --sport 80 -m state --state ESTABLISHED -j ACCEPT

#
# Set access for localhost
#
iptables -A INPUT -i lo -j ACCEPT



#
# List rules
#
iptables -L -v

Will the Windows 8 Recovery USB "Reset" Option work on a blank HD?

Similar questions have been asked before at various times, but there is no clear answer on THIS question.


Neither do the instructions for the Windows 8 Recovery USB provide much of an answer.


Say I have a Lenovo notebook with Lenovo Windows 8 Pro OEM Version installed.


I use the utility to create a Windows 8 Recovery USB, which copies the recovery partition to USB.


Now i have a Windows 8 Recovery USB. Among the options with this USB is "Resetting your PC," which, according to Microsoft:



...reinstalls Windows but deletes your files, settings and applications – except for the applications that came with your PC. Restoring your PC is a way to undo recent system changes you’ve made.



What this does NOT tell me is whether "resetting my PC" works if Windows has been COMPLETELY ERASED from the SSD - a scenario in which "resetting" does not "delete your files, settings and applications" because the drive is completely blank.


For instance, if I wiped and repartitioned the SSD, installed Debian on it, and then, a year down the line, decided I wanted to wipe Debian and to return to the OEM Windows 8 Pro.


So the question is:


If I wipe the drive completely, will I be able to reinstall Windows on my computer using the "reset your pc" option on my Windows 8 Recovery USB?

windows 10 - Windows10 Install disk does not offer UEFI option

I have a hp notebook (HP 240 G5 with an Intel Core i3-5005U CPU) with a preinstalled 64 bit Windows 10 Home Single Language.



For testing my software I need to install additionally a 32 bit Windows 10 on that machine.




I created a new partition "Win32" where I want to install the 32 bit Windows 10:



Paritions



The existing partitions are GPT, so I need to install the new image via UEFI. Legacy BIOS mode is useless as it requires MBR partitions.



I used the Microsoft download tool (MediaCreationTool.exe) to download the latest 32 bit Windows 10:



Download Windows 10




I get an ISO image of 2.836.660.224 bytes which is NTFS formatted.



I use Rufus to copy it on a USB stick:



Rufus



I turned off Secure Boot and changed the boot order:



UEFI Settings




But when I try to boot from the USB stick it does not appear in the menu:



Boot Menu



It does not matter if I copy the ISO image to a USB stick or to a DVD.
The result is the same.



When I select "OS Boot Manager" the Windows on harddisk is started.



When I select "Boot from EFI file" I get this menu where I chose the USB stick:




Boot from EFI file



And then a menu with 3 files is shown.
The strange thing is that the BIOS shows me files that do not exist on the USB stick. The only existing file in the ISO image is
\efi\boot\bootia32.efi



Boot from EFI file



No matter which option I select in this menu, I get the same error:




Boot from EFI file



Obviously, because the file bootx64.efi does in deed not exist.
But I also get this error after selecting the file bootia32.efi.
Very weird!



Then I thought: 'Ok I will simply copy this missing file from the 64 bit Windows 10 Installation DVD.' And in deed the above error disappears. But a few seconds later I get an error C0000359:



Error C0000359




Then I downloaded the ISO image for installing both: 32 and 64 bit.



MediaCreationTool



The ISO file has a size of 6,5 GB! (I remember installing Windows 3.1 from 15 diskettes). When booting there is no option in the menu to chose booting from USB stick. Again I chose the EFI file manually:



bootmgr.efi



And then in deed I get the expected menu:




Install Windows 10



but no luck:



Error C0000359






The interesting thing is that I have another ISO image with ONLY the 64 bit version of Windows 10 and I get the correct boot menu:




Boot Menu



When I proceed, the installation continues normally and I get the screen where I can chose the partitions.



Isn't that strange? The 64 bit-only ISO is functioning correctly while the 32+64 bit ISO is failing.



So what is wrong here?
One of three ISO files runs and the other two fail.




I have read that the Intel Core i3 processor should be capable to run a 32 bit or 64 bit operating system.

Monday, January 6, 2020

Changing Administrator password Windows Home Server

Is there a problem using Computer Management > Local User and Groups > Users to change the Administrator password in Windows Home Server? Is there a chance it will cause any issues with the system? I ask as the system warns against using server tools to change settings. I have access to the system with my account, but the Administrator password isn't working,forgotten whatever and needs to be changed.

Page table memory leak in Windows 10

I have a memory leak which is cosuming almost all 10GB of my physical RAM. It is not visible in the task manager.


I have followed a few guides on the internet using different tools like RAM map and process explorer and what I could determine, I think I may have a leak in the page table.


The most relevant guide I have found so far is from this post: https://superuser.com/a/769002 but unfortunately, the process name is coming up as "Unknown". Is there any way to find out what this process is?


Thanks.

Sunday, January 5, 2020

How to configure Windows Firewall to allow all ports in use by IIS Express

My understanding of this technet article, per the page that brought me there*, is that I can configure the Windows Firewall to allow all inbound traffic on any port being used by a specified executable.



I realize the defacto answer is likely to be "Don't do this", so please understand; I'm running Visual Studio and IIS Express inside a virtual machine, and want to be able to connect from the host OS for testing purposes, and thus not really concerned with the security implications of opening all ports being used by IIS Express.



I created an inbound rule with Program set to %ProgramFiles% (x86)\IIS Express\iisexpress.exe, which is the executable running according to the task manager. All other rule specs are left empty (any local address, any remote address, and local port, any remote port, "any" allowed users, "any" allowed computers). Yet, the connection only works if I have a rule for the specific port being served up by IIS Express.




Since it would make my life easier (and largely on principle since technet says it should work), I'd rather not have to add a firewall rule for each app I create.



* Task "Create a rule that allows a program to listen for and accept inbound network traffic on any ports it requires."

hard drive - New HDD showing CAUTION status











enter image description here
This drive of mine is less than 2 weeks old. And why am I seeing this CAUTION status? Help please. This is very stressing...


Answer



Purely technical answer:




You are likely seeing the CAUTION state because it found a value at the highlighted part (C5) which was outside its threshold.



Now if you means what does this mean: First read those values mean. Start with this page on wikipedia.



Then relax. The raw values column is a mere one.


keyboard shortcuts - Just installed Windows 10 - alt+tab stops working a few seconds after boot



Yesterday I inserted a brand new SSD drive into my laptop and installed Windows 10 Enterprise. Most things work ok, and I am getting used to the new interface (coming from 8.1). However, alt+tab does not work. The only result of pressing the combo is that the current window loses focus.



I tested right after a boot and it works briefly, but then stops having any positive effect after a while. Win+Tab works but the alt+tab shortcut has long ago become muscle memory so I want to keep it. :)



I am thinking that there is some sort of software I installed that caused this since it works for a while after boot. AquaSnap Pro has some keyboard shortcuts but none that go near alt+tab as far as I can tell. Greenshot also has some but should not block it either. I am not currently running AutoHotKey even if I want to once I figure this out.




Is there a way to see what "happens" in the OS when you press a hotkey like this, and figure out which application "eats" the event?



Any other tips on getting my alt tab back?


Answer



Here is the solution to what was going on;



I use Launchy (2.5/2.6b doesn't matter) with Alt+Esc as the hotkey for activation. This apparently does not make Windows 10 happy. It worked fine with Windows 8, Windows 7, Windows Vista and probably XP before that (long time Launchy user).



If I change the Launchy hotkey to for instance Ctrl+Space or Alt+Space, Alt+Tab keeps working as expected.




I know that Alt+Esc has an action attached to it in Win10, but I did not realize it would react like this to having one of the hotkeys overwritten. So I dunno if this would need to be "fixed" in Win10 or in Launchy - neither is very likely anyway so I better get used to the new key combo.


What can I use to measure the bandwidth a specific Windows application uses?



Ideally, I'd like to hear of an application to show how much bandwidth each application is consuming on my local Windows PC. Alternatively, instructions to use any other application for this purpose. The simpler the better. Something that works for Windows 2000/XP/Vista/7 (if possible).




Any ideas? Thanks.


Answer



Check out NetLimiter. The free Monitor version does everything you want.



alt text


Saturday, January 4, 2020

How can I access the contents of a lock-out password-protected USB flash drive?

I have a password protected Cruzer U3 flash drive. When trying to access the data contained on this drive, I typed the password incorrectly, and it is no longer prompting me for a password. I cannot access the drive's contents. Some Google searches* turned up a page on Lockergnome that describes a situation similar to mine. However, none of the solutions I found appears to be viable. All of them suggest that I format my drive, which contains incredibly important documents. Is there an alternate way to retrieve my data without formatting the drive?


* Search terms included "Bypassing U3 password lock", "Unlocking locked USB flash drives", and "U3 Cruzer recovery"

windows - How to upgrade SSD firmware on Intel RST RAID 0 member disk?


I have a random bunch of SSDs working in an Intel Rapid Storage Technology RAID 0 to serve as my system drive.


INTEL RST RAID 0


To setup an Intel RST RAID drive, in UEFI one must change the SATA controller to RAID, then enter Intel's pre-OS RST mangement area


One of these disks has a firmware update available which was given the highest update classification by the manufacturer:



Important


These firmware updates address critical bugs which improve the
reliability and performance of your SSD. It is highly suggested to
update your drive as this will ensure the SSD continues to operate at
its optimum level.


>     ARC 100 Firmware v1.01
>
> Release Notes
>
> Improvements since v1.0
>
> Fixed a corner case issue with DDR corruption on 480GB capacity drives
> Improved robustness of uncorrectable error handling
> Improved read retry on bad block list
> Numerous stability and reliability improvements


When I try to update the firmware using the software provided by the manufacturer, the member drive is not listed because the RAID 0 drive is what the system sees.


I use daily backups with Windows Home Server 2011, so it's quick and easy to restore my system. Still, it's not so fast that I want to remove the member disk just to update the firmware.


What are my options to upgrade the firmware?


Note: I am not using a Windows software-RAID. As far as Windows is concerned this is a real disk. I am using a software-RAID in a sense: the RAID controller is probably just software on a chip that came with my motherboard. Anyway, answers considering a Windows software-RAID are also interesting and welcomed.
Illustration showing that motherboard RAID appears as a normal disk at the OS level.
Illustration showing that motherboard RAID appears as a normal disk at the OS level


Answer



One option is to boot into Linux using a live disc, and then run the firmware updater for Linux from there.


Example steps


The following is an example process of how to do this in Windows using free software.


Create a bootable USB flash drive


See the article Create a Bootable USB Flash Drive on TechNet, or follow these steps:



  1. Open a PowerShell terminal and run diskpart.Open the terminal as an adminstrator if DiskPart doesn't elevate automatically.


  2. Type list disk:




Disk      Status         Size     Free     Dyn  Gpt
-------- ------------- ------- ------- --- ---
Disk 0 Online 670 GB 0 B *
Disk 1 Online 7728 MB 0 B



  1. Select the USB device and clean it:



DISKPART> select disk 1
Disk 1 is now the selected disk.
DISKPART> clean



  1. Create a partition, format it and make the drive bootable:



DISKPART> create part pri
DISKPART> select part 1
DISKPART> format fs=fat32 quick
DISKPART> active
DISKPART> exit


Create the live disc.



  1. Download Ubuntu Desktop

  2. Burn the image file to your USB device using YUMI. Be sure to make a persistent file for storing changes.

    YUMI Ubuntu


Update firmware


It wasn’t necessary for me to disable the RAID controller in the UEFI. So simply boot into the live disc and run the update software:



  1. Make sure your UEFI/BIOS is not set to Ultra Fast boot mode, or something similar that prevents booting from USB drives.

  2. Boot into Linux, without installing it.

  3. Download and run the firmware update software. If you can’t run it, make sure it's executable (i.e. sudo chmod u+x ~/Downloads/SSDGuru):
    SSDGuru running in Ubuntu will detect OCZ's drives, even when they are members of an Intel RST array

  4. Verify the firmware was updated by rebooting into Windows or the live disc:
    SSD Arc100 Firmware Version as seen in Intel RST UI


Friday, January 3, 2020

macos - Mac disk is full but I can't figure out why

I have a 500GB SSD on my macbook running Yosemite.


Recently, I have been getting a lot of out-of-disk space message. I have been deleting and deleting. According to every disk usage application I have tried (including Disk Expert, Disk Wave, Omni Disk Sweeper) I am using about 130GB.



  • 32 GB Applications

  • 10 GB Library

  • 8 GB System

  • 80 GB Users


Yet the Mac says only 13GB out of 512GB are free. So there is a huge discrepancy. I have cleaned log files and caches. I have run disk check which has reported no errors. I have rebooted (naturally). None of the tools above showed the missing data.


Moving to the command line, I find what looks like the symptom of the problem:


$ sudo du -cxhd 1 /
338G /.DocumentRevisions-V100

My guess then is that the versioning feature has run amok. How can I address this discrepancy between the used disk space and the free disk space?

computer building - How do I choose hardware for a gaming machine, and which components are the most important ones?








I am looking into building a gaming computer from scratch. I have a certain knowledge of what I will need, but I want to get a better understanding of what is really necessary for as flawless a gaming rig as possible on a budget.



What I know is that I need a powerful graphics card and CPU, and for the most part, not much else, as games dont require a ton of RAM, Hard Drive space, etc. What I don't know is what constitutes a "powerful" graphics card and CPU.



Basically what I need is for someone to explain what the different specs of computer components (mostly CPU, graphics card, and motherboard) mean, and which ones are important to a good gaming computer.



Also, on a similar note, I am not sure how to choose a power supply that will support all the components that I ultimately buy. Is there a tool out there that I can use for this?

hard drive - Bad performance on Windows 7 with Bad sectors

Since a month ago everything was right with my laptop. And then Windows started crashing.
Now my windows is stuttering every 5 seconds and fails to perform smoothly any operation. There were no bad sectors. Two appeared and after I ran the chkdsk utility it says that I have 10 bad sectors on my hard drive! What's going on? I made a dual booth with Linux so that I can use my computer at least, and I have no problems with Linux. Can it be system related.

I got a lot of crashes and from what I see they are all
KERNEL_INPAGE_FAULT_DATA which means there is corruption in the pagefile.sys, but when I deleted it nothing changed. I use my Linux OS with no problem.



The most likely reason is that ntoskernel.exe is corrupted -----> the paging system in the kernel causes bad data to be written hence when I re-open a window the corrupted data to the RAM.



Should I wipe my disk to zero-fill the bad sectors? is there another approach? Will wiping the windows partition also delete the Linux partition? Well I don't have any important stuff on my Linux, and I can backup my data on the Windows side.



Does HDD Regenerator work? I'm tempted to test it, but I can't seem to rely on any user feedback.

mac - Does A Hard Drive's Read / Write Speed Affect The Speed Of A Data Wipe / Erase / Sanitise?


I have multiple hard drives that I need to test & Wipe. I have testing software (Drive DX) for my MacBook and I'm using Apple's built-in Disk Utility to wipe the drive to DOD 5220.22-M standard. I am using a hard drive docking station to connect to my MacBook.


My issue is time. It is taking an excruciatingly long amount of time to test and wipe. The full test is around 2 hours for a 1TB drive, which isn't awful but could be better. The wipe seems to go on for hours and hours without an end in sight. (It's a 7 pass wipe which I know takes some time but it shouldn't be that long!)


My current HDD Docking station is USB 2.0 (data transfer of just 480mb/s). I was about to invest in a docking station that will connect either to the USB 3.0 (5GB/s) or the Thunderbolt 2 (20GB/s) on my MacBook - but stopped myself as I ask this question.


Will the data transfer speed of the Docking Station / Cable even matter if the Hard Drive has a Read / Write speed of say 100Mb/s? Does that affect how quick I can test & Wipe the HDD? And Does data transfer speed affect the speed of which I can test / wipe anyway?


(I'm sorry for the essay, any help will be much appreciated!!)


Answer



Your computer/OS doesn't have a way to issue a "go off and do a 7-pass wipe of yourself" command to your hard drives. So to do a 7-pass wipe of a 1TB drive, your computer has to write 1TB of zeros to the drive, then 1TB of ones, then 1TB of random data, et cetera. So your computer has to write about 7TB to the drive. That's 7,000,000,000,000 bytes * 8 bits per byte = 56,000,000,000,000 bits that your computer needs to write to your drive for a 7-pass wipe of the whole drive. If you've connected your 1TB drive over USB 2.0 High Speed (480Mbps), divide that 56 trillion by USB 2.0's 480,000,000 bits/sec and you get 116,667 seconds = 32 hours = 1 day, 8 hours.


But USB 2.0 is famous for not really having 480Mbps throughput. It's probably more like 200Mbps, which works out to about 78 hours (about 3 days, 6 hours) for your 7-pass wipe of a 1TB HDD over USB 2.


So, yes, for fastest 7-pass wipes, connect your HDD to your computer via a bus whose real-world throughput meets or exceeds that HDD's max sustained sequential write speed.


Edited to add: Also, please be very careful about units. HDD manufacturers use standard decimal SI units of 8-bit Bytes. So a 1TB HDD stores 8 trillion bits. The read/write speeds that your HDD maker claims are also in standard decimal SI units of 8-bit Bytes, so an HDD that claims a 100MB sustained/sequential write speed means 100 million bytes per second, or 800 million bits per second.


In contrast, I/O bus speeds (besides SATA) are almost always in standard decimal SI units of 1-bit bits per second. So USB 3.0 "SuperSpeed" is 5 billion bits per second, USB 3.1 gen 2 "SuperSpeed+" is 10 billion bits per second, Thunderbolt 1 is 10 billion bits per second, Thunderbolt 2 is 20 billion bits per second, and Thunderbolt 3 can supposedly get up to 40 billion bits per second.


I don't know what the sustained sequential write performance of your HDD is, but if it's, say, 100MB/sec = 800Mbits/sec, then a 7-pass wipe is going to take at least 19 hours no matter how fast of a bus you use to connect it to your computer.


autohotkey - Remap Alt+Tab function


My keyboard tab key is not working. How I will remap the functionality of alt+tab to alt+capslock ? And without making capslock to goes on and off when capslock key is pressed while holding alt key.


the 1 key(not in the numpad) is also broken. How I will make to alt+2 = 1 and alt+shift+2 = exclamation(!)


PS: I don't have knowledge in autohotkey yet. I just want to remap those broken keys. Thank you :)


Answer



this autohotkey script should do what you want:


!Capslock::!Tab ; map alt+Capslock to alt+Tab
!2::send 1 ; map alt+2 to 1
!+2::sendraw ! ; map alt+shift+2 to !

command line - CMD batch escaping environment variable in params



I have to write a batch file with a environment variable a param:



c:\myapp.exe -f "%APP_HOME%\file.conf" 


I need to pass exactly the string %APP_HOME% as param and not its value. How can I do?



In other words, I don't want to strip the variable in the batch runtime but I would like to let the application use it as parametrized path, if I change this environment variable I don't want to change the variable in the application.



Answer



I need to pass exactly the string "%APP_HOME% as param




  1. Replace % with ^%

  2. Remove the "s



    c:\myapp.exe -f ^%APP_HOME^%\file.conf





test.cmd:



@echo %1 %2 %3


output:



F:\test>test c:\myapp.exe -f ^%APP_HOME^%\file.conf
c:\myapp.exe -f %APP_HOME%\file.conf
F:\test>






Further Reading




windows 8 - Cannot change brightness on Sony VAIO Fit 15

I've begun to notice that periodically on my Sony VAIO Fit 15 (model number SVF15A1C5E) I can no longer change the screen brightness. Using the Fn+F5 and Fn+F6 shows Windows 8 the brightness overlay, but the screen brightness doesn't actually change, and the option in Power Options also has no effect. The problem can sometimes be alleviated by rebooting.



This YouTube video illustrates the same problem I'm experiencing, although it's a different VAIO model.



Having reviewed the recommendations on this Microsoft Community discussion, I've tried the following:




  • Upgraded to the latest Intel HD 4000 and NVIDIA GeForce GT 735M graphics drivers (10.18.10.3412 and 334.89, respectively)


  • Upgraded to the latest version of VAIO Control Center (6.2.11.09270)

  • Disabled the "Enable adaptive brightness" option in all power plans, despite my model not having an ambient light sensor:
    Power plan settings

  • Checked for a "Screen brightness" setting in VAIO Control Center, under "Image Quality"; no such option exists:
    VAIO Control Center, Image Quality



Some have recommended to only use graphics drivers provided through Sony. I've tried this in the past, only to see the same problem. Nevertheless, VAIO Update does show an older version for my NVIDIA graphics card (from October 2013).



Has anybody else experienced this? Is there a way to definitively resolve this specific problem?

Thursday, January 2, 2020

How do I delete Windows.old in Windows?

I used to run Windows 7 32 bit, but installed the 64 bit version because of a RAM upgrade. During the installation I got this message:




The partition you selected might contain files from a previous Windows installation. If it does, these files and folders will be moved to a folder named Windows.old. You will be able to access the information in Windows.old, but you will not be able to use your previous version of Windows.




The C:\ drive now has two (2) Windows folders:





  1. Windows (15.3 GB)

  2. Windows.old (15.7 GB)



screenshot showing windows.old folder



Don't see why I need the Windows.old taking over 15GB of space on my hard drive so I tried to delete it. It didn't work.



How can I safely delete this folder?

Do electrical spark sounds from the power plug hint for higher risk of damage?


I was moving my PC while it was turned on (at the Windows 10's Login screen) when I heard some electrical spark sounds from the back and the PC fell out. Looking at the back I noticed that I didn't push the power supply cord firmly into the PC socket, so it fell out while I was moving the PC.


Now from what I've read, a PC shutting off unexpectedly could mainly corrupt files and to a lesser extent damage hardware. My PC is running normally afterwards and chkdsk didn't find any problems. But what I am really worried about were the electrical spark sounds because of the power supply being a bit loose.


Do these sounds hint for surges and/or electrical fluctutations within the PC before it fell out, which give a higher risk of damaging the hardware? In other words, was it more safe if the plug got disconnected immediately instead of creating sparks for a short time first?


Answer



If everything is working and chkdsk shows no problems, the incident doesn't seem to have hurt anything. There isn't anything I can think of that could have been damaged in a way that wouldn't be apparent (and even if it was, there would be no way to detect it or do anything about it). You don't need to "wait for the other shoe to drop".


If the power cord fell out only because it hadn't been pushed in all the way, some arcing wouldn't be unexpected in the process. A one-time, momentary event isn't a problem.


It would be a problem, though, if the plug is really loose even when properly pushed in. In that case, it could produce recurring arcing that would eventually degrade that connection. That condition can lead to the plug getting extremely hot, to the point where it fails in a nasty way. So if the cord isn't snug when properly pushed in, get a replacement cord.


Windows 10 update to 1511 installation fails


I'm having problems updating to the Windows 10 November Update (1511) with an error saying "Something Happened"


enter image description here


I've tried to update using


I've also



  • Run the Windows Disk Cleanup Tool

  • Run the Windows Update troubleshooter


    This one always finds two errors which it says that it fixed:



    • Potential error in Windows Update database were was discovered: 0x80070490

    • Windows Update components must be repared


  • Executed sfc /scannow in an elevated command prompt

  • Executed dism /online /cleanup-image /restorehealth with an ISO as source

  • Renamed the C:\Windows\SoftwareDistribution\Download folder




What else can I try?


Answer



Something is extra or corrupt in your installation that isn't in others; so, you'll want to trim down:



  1. Uninstall your antivirus, firewall and other possibly intervening software; disabling isn't enough.

  2. Disable everything that doesn't need to start in msconfig to avoid further intervening trouble.

  3. Run dism /online /cleanup-image /restorehealth to fix your Windows packages' health

  4. Consult the Event Viewer and log files (WindowsUpdate.log, setupact.log, setuperr.log, ...)

  5. Try installing again whilst using Process Monitor such that you can investigate or export a report about what is really happening before it gives the message box; it'll help figure out the last log it has written too, as well as which files and service entries were accessed last.

  6. Beyond this point you could create a new user and uninstall as much software and drivers as possible; but really, at this point you might as well do a fresh Windows 10 Build 1511 install.


Wednesday, January 1, 2020

Does a full retail Windows 8 license grant me the right to install Windows 7 instead?


If I buy a full retail Windows 8 license am I granted the right to install a down-level version of Windows, specifically Windows 7, instead? Just to be clear: I buy a full retail Windows 8 license - full version (not upgrade) and retail, not OEM. But rather than installing Windows 8, I want to run Windows 7. Is this allowed?


Answer



No. Downgrade rights (which is what I assume you're thinking of) only applied to the Vista/XP era.


If you want to buy a license for Windows 7, there is nothing stopping you from purchasing an OEM license, or buying it outright from an online retailer.


Unless you buy an OEM license of Windows 8, which more information is available here.


http://www.microsoft.com/oem/en/licensing/sblicensing/pages/downgrade_rights.aspx#fbid=dVb0lSch56Y


bash - Is there really no way in Linux to get creation time for files on cifs/smb share?



I am embarrassingly far along in a bash backup script and have missed something major. I know that ext3 filesystems don't track creation date, but copying files within ext3 updates the changed time as seen via stat (which would work). However, when files are copied from one Windows server to another (whose mounts I have via smb/cifs), from my testing, changed time is not updated. I'm using find to do the searching on the cifs shares. Is there really no way to detect when a new file is created over a cifs share from Linux using "find"?



Also, I am very familiar with rsync, and in this circumstance rsync's limitations rule it out as an option. I was thinking I could use rsync for the searching and try to pipe the results to the action (gzip), but I think the subshells would be ridiculous. Could be wrong, of course. Any suggestions would be much appreciated. Can provide more detail, but from my research I don't think it's possible.


Answer



The Linux kernel has had an xstat(2) system call in the works for several years, now. David Howells of RedHat did much of the work. xstat(2) allows one to retrieve the creation time (sometimes rechristened the "born time" or "birth time" in the Linux and BSD worlds for no really good reason) of files from the several filesystems that support it, including EXT4 (which has a creation timestamp on disc) and CIFS (which with its DOS/OS/2/Windows heritage has supported a creation timestamp as a first class citizen for decades). M. Howells worked on the CIFS patches that go along with the system call.



OpenSolaris and the BSDs actually do have a st_birthtim datum in their stat(2) system call right now, and the feature is accessible to script writers via application programs such as find and ls. On the OpenSolaris ls man page you'll find crtime alongside atime, mtime, and ctime in several places. Similarly, the FreeBSD find command has -Bmin, -Bnewer, and -Btime primaries. And the Mac OS ls has a -U option.




If you were writing your script for OpenSolaris, the BSDs, or Mac OS 10, you could just get on with whatever you want to do with creation times right now. Indeed if you were writing for Windows you could do the same. Cygwin has supported st_birthtim since 2007, making Win32's CreationTime timestamp, which it has had since the first version of Windows NT and which Windows NT maintains on both NTFS and FAT volumes, available to Cygwin tools.



However, the same isn't true in the GNU Linux world. Creation time capability has yet to make it to GNU coreutils' ls or to GNU findutils' find. Indeed, it isn't even part of the mainstream Linux kernel yet. Part of the problem is that the xstat(2) system call got bogged down in a diversion where people wanted to keep three timestamps, instead of have four as in the Windows NT kernel API, and dump ctime to replace it with crtime.



Linus Torvalds' response in 2010 was that "it's all totally useless and people can't even
agree on a name" and "Let's wait five years".



In fact, as I suspect most people reading this will know, the world has been widely agreeing the name "creation time" since the 1980s and we've been waiting at least 25 years already. It's the name used in OS/2 1.0; it's the name used in VMS ODS-1; it's the name used in Windows NT 3.5; it's the name used in SMB; and it's the name used in the question. ☺




Further reading




Dual boot Linux / Windows 7 + Window 7 virtual machine under Linux + licensing


  1. Is it legal to use single Windows 7 (home basic) license to install windows on host AND on virtual machine running under Linux on the same host?


    It will be physically different installations (different partitions), however in the same pc so they will never run at a the same time. Although frequent reboots between two could happen.


  2. How to do activations in this case? Just install on host -> activate -> reboot into linux -> install under VM -> activate?


hard drive - Leaving bad sectors in unformatted partition?

Laptop was acting really weird, and copy and seek times were really slow, so I decided to scan the hard drive surface. I have a couple hundr...