Friday, June 30, 2017

windows - Not able to go back from Win10 1709 to 1511 because of Administrator User Account


I have a client which was on Windows 10 Pro version 1511.


The computer was updated to Windows 10 Pro version 1709 without our approval and some functions (assigned access in particular) don't work anymore as they're supposed to.


Now I want to go back to 1511. Unfortunately, my co-worker setup the integrated "Administrator" user account after the update.


Now whenever I want to go back to 1511 Windows tells me that I need to delete the newly created User-account (Administrator) before I can go back to 1511.
Screenshot (in german)


it also tells me where to do this. in settings > accounts > other users (or similar, I translated that on the fly)


but there I don't have any administrator user account showing! screenshot proofing there's no administrator (also in German)


My question is, how can I go back to 1511 without deleting the admin account? or how can I delete the admin account?


Answer



To properly delete accounts you have to remove multiple pieces within Windows. The user account itself is the obvious pieces. If you run lusrmgr.msc which will give you a MSC interface to list the local users and groups.


Local users and groups manager
Picture taken from Users and Groups technet discussion


If you delete a user within that interface it might not be fully removed. A user profile might still have system wide associated registry keys and/or files in the actual file system. The files of user profiles are (by default) kept in C:\users\.


In order to properly dispose of these files there is also a GUI element available. Hit Win+Pause to open your system information. On the left hand side you will find an extended/advanced system settings option that will bring up another dialog that allows you to select "user profiles". Within that dialog you will be able to select local user profiles and delete them.


Dialog to delete local user profiles
Picture taken from How do I delete a user profile on a Windows 7 machine that is part of a domain? on SuperUser


Even with these options deleting the Administrator account from a machine is probably a bad idea. The first dialog will warn you that you won't be able to recreate the SID of a user you delete. The Administrator account has a special SID which might have special permissions in certain cases. Deleting the files on the other hand shouldn't be much of an issues as those will be recreated from the default profile. Manually deleting the files from C:\Users might still lead to various issues, so following a proper procedure is a good idea.


Are universal power supplies for laptops worth it?


My laptop's cable broke and sadly it seems like I need to buy a new power supply.


What I wonder is, I've found that universal power supplies are much cheaper than the official HP ones. Are they really worth it?


Another question: the original supply has these specs: 65W, 18.5V, 3.5A.
However the universal supplies are more powerful (90W, 100W) and come in integer voltages (17V, 18V, 19V, etc). Are they compatible? Should I set them to 18V or 19V?


Answer



The usual take on this is: They may work but if anything goes wrong, then don't expect your warranty on the device to hold. At least that's what the manufacturer will tell you.


The power just specifies how much the power supply is able to supply but it won't affect how much your laptop is going to use to charge the battery.


As for the voltage, using 18 or 19 V should work without damaging anything, but be sure to try with 18 first :-)


Thursday, June 29, 2017

macos - Switch the keys caps lock and shift


Is there a way to switch the shift key with the capslock key?


I have a problem with the shift keys, and I would like to use the caps lock keys, instead of the left shift key.
Mac OS X settings allow to modify the keys used for some modifiers, but it doesnt't allow to change the key used for the shift key, nor to select the shift keys as alternative key for another modifier.


Answer



I found http://pqrs.org/macosx/keyremap4macbook/, which allows, in example, to swap fn with left shift (it actually allows to remap fn to left shift, and left shift to fn, among other things).


hardware rec - Browsing laptop models by display resolution

To put it shortly, is there a place where one could browse laptop models of different manufacturers, by screen resolution.


(I have some software which depends on display resolution, and therefore need a laptop with either 1400x1050 or from that line)

remapping - Autohotkey Ctrl+Shift - Zbrush/Photoshop

I have been using Autohotkey for a long time to remap keys inside CG softwares (mainly Zbrush and Photoshop) to make them more lefty-friendly.


Essentially, I remap the Numpad keys to keys you can't change inside the programs (Ctrl, Alt, Shift, etc...). This way I can use my graphics tablet pen with my left hand and access Ctrl, Alt, etc. using the Numpad, which is much more convenient than offsetting the whole keyboard to the right.


Anyway, here is my script :


 #IfWinActive, ahk_class ZBrush
#MaxHotkeysPerInterval 200
NumPad1::Alt
Numpad2::LControl
Right::Shift
up::Space
return

Pretty simple, but I have had a bug with it ever since I created it several years ago. Essentially, when I am pressing and holding Numpad2+Right (Ctrl+Shift), and release Numpad2, the program behaves as if I was still pressing it. Repressing Numpad2 real quick sets it back to normal but it's very annoying. Here are a couple of images to better illustrate the issue :


enter image description here


Do you know why this happens? I am no programmer, so I could definitely use some help.

windows 7 - Name resolution DNS Client Event, DNS servers not responding, with internet disconnects


I have a really small network in my house, with only three computers. Recently I've experienced my computer disconnecting from the internet for 3-5 seconds, and it only happens two or three times a day. I get this Warning message in the event logs:


Event ID 1014, Warning
Name resolution for the name dns.msftncsi.com timed out after none of the configured DNS servers responded.


The website dns.msftncsi.com isn't a constant, it's been a few random sites (i'm guessing whatever site i'm on at the time of disconnect.)


My network consists of a windows 7 Desktop, Linux mint laptop, and a macbook pro. My router is a Netgear N600, and here's my output of ipconfig /all


ipconfig /all
Windows IP Configuration


Host Name . . . . . . . . . . . . : Red
Primary Dns Suffix . . . . . . . :
Node Type . . . . . . . . . . . . : Hybrid
IP Routing Enabled. . . . . . . . : No
WINS Proxy Enabled. . . . . . . . : No


Ethernet adapter Local Area Connection:


Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Realtek PCIe GBE Family Controller
Physical Address. . . . . . . . . : 44-87-FC-D4-21-89
DHCP Enabled. . . . . . . . . . . : No
Autoconfiguration Enabled . . . . : Yes
Link-local IPv6 Address . . . . . : fe80::5be:cd97:4f07:2f24%11(Preferred)
IPv4 Address. . . . . . . . . . . : 192.168.1.25(Preferred)
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . : 192.168.1.1
DHCPv6 IAID . . . . . . . . . . . : 239372284
DHCPv6 Client DUID. . . . . . . . : 00-01-00-01-19-43-0D-0A-44-87-FC-D4-21-89
DNS Servers . . . . . . . . . . . : 192.168.1.1
NetBIOS over Tcpip. . . . . . . . : Enabled


Ethernet adapter VMware Network Adapter VMnet1:


Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : VMware Virtual Ethernet Adapter for VMnet1
Physical Address. . . . . . . . . : 00-50-56-C0-00-01
DHCP Enabled. . . . . . . . . . . : No
Autoconfiguration Enabled . . . . : Yes
Link-local IPv6 Address . . . . . : fe80::5d7c:587a:4b9:333b%14(Preferred)
Autoconfiguration IPv4 Address. . : 169.254.51.59(Preferred)
Subnet Mask . . . . . . . . . . . : 255.255.0.0
Default Gateway . . . . . . . . . :
DHCPv6 IAID . . . . . . . . . . . : 318787670
DHCPv6 Client DUID. . . . . . . . : 00-01-00-01-19-43-0D-0A-44-87-FC-D4-21-89
DNS Servers . . . . . . . . . . . : fec0:0:0:ffff::1%1
fec0:0:0:ffff::2%1
fec0:0:0:ffff::3%1
NetBIOS over Tcpip. . . . . . . . : Enabled


Ethernet adapter VMware Network Adapter VMnet8:


Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : VMware Virtual Ethernet Adapter for VMnet8
Physical Address. . . . . . . . . : 00-50-56-C0-00-08
DHCP Enabled. . . . . . . . . . . : No
Autoconfiguration Enabled . . . . : Yes
Link-local IPv6 Address . . . . . : fe80::dd6e:74c6:5254:2215%16(Preferred)
Autoconfiguration IPv4 Address. . : 169.254.34.21(Preferred)
Subnet Mask . . . . . . . . . . . : 255.255.0.0
Default Gateway . . . . . . . . . :
DHCPv6 IAID . . . . . . . . . . . : 352342102
DHCPv6 Client DUID. . . . . . . . : 00-01-00-01-19-43-0D-0A-44-87-FC-D4-21-89
DNS Servers . . . . . . . . . . . : fec0:0:0:ffff::1%1
fec0:0:0:ffff::2%1
fec0:0:0:ffff::3%1
NetBIOS over Tcpip. . . . . . . . : Enabled


Tunnel adapter isatap.{9420D2B3-C8C4-48EA-BCC1-55C52E1E9CEE}:


Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Microsoft ISATAP Adapter
Physical Address. . . . . . . . . : 00-00-00-00-00-00-00-E0
DHCP Enabled. . . . . . . . . . . : No
Autoconfiguration Enabled . . . . : Yes


Tunnel adapter Teredo Tunneling Pseudo-Interface:


Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Teredo Tunneling Pseudo-Interface
Physical Address. . . . . . . . . : 00-00-00-00-00-00-00-E0
DHCP Enabled. . . . . . . . . . . : No
Autoconfiguration Enabled . . . . : Yes


Tunnel adapter isatap.{CD33946C-2519-4ADC-B106-55C7C18757C4}:


Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Microsoft ISATAP Adapter #2
Physical Address. . . . . . . . . : 00-00-00-00-00-00-00-E0
DHCP Enabled. . . . . . . . . . . : No
Autoconfiguration Enabled . . . . : Yes


Tunnel adapter isatap.{35A4120D-DF3E-41D6-89BB-5E7B0D2AD40A}:


Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Microsoft ISATAP Adapter #3
Physical Address. . . . . . . . . : 00-00-00-00-00-00-00-E0
DHCP Enabled. . . . . . . . . . . : No
Autoconfiguration Enabled . . . . : Yes


I've been troubleshooting this for a while, and really am out of ideas. I have only noticed the problem on my windows 7 desktop, but that could be because my laptops are normally only on at work or school. Thanks in advance, and let me know what other information might be needed.


Answer



As it turns out, my disconnects were from my ISP not having a large enough pipeline for my neighborhood, and they also had to replace the switch I was on. The errors make sense now that I know what the problem was, but I really didn't expect this since I couldn't even tracert to my ISP (which was because the initial switch I was on was going in and out at the same time.) Thanks for all of the help, but my ISP has fixed both problems now (they are a super small ISP, with like 10 employees total).


Wednesday, June 28, 2017

installation - How can I create a pen drive that I can boot from, and then install Win98 from?

I have a HP Compaq t5515 thin client computer with a flash disk and USB port. I want to put Win98 onto it, replacing whatever is on there now (I think it is some Linux-based thing). I can find stuff about putting Win98 onto a pen drive and running from that, but I can't find any info about installing Windows 98 from a pen drive onto a sep[arate system.


Is it just a matter of



  • making the pen drive bootable to DOS

  • copying the contents of a Win98 installation CD onto the pen drive

  • booting the HP machine from the pen drive

  • running SETUP.EXE from the pen drive?


Any pointers appreciated.
TIA

Windows 7 USB stick and (late 2010) Macbook Air

If you install Windows 7 into the Boot Camp partition from a USB drive, it will apparently become impossible to boot from that USB drive on that Mac again. I'm trying to find out why.


This is the sequence of events (normal & boring):



  • Create bootable Windows 7 Setup USB drive (the usual way: diskpart, clean, create partition primary, etc, etc)


  • Prepare Mac with Boot Camp Assistant and rEFIt.


  • Boot Mac from USB drive (works great), install Windows


  • Everything's great, Windows works, OSX works, rEFIt allows booting either one



Now the strange part:



  • Insert the bootable USB drive again (because, I don't know, I want to run the repair tools on it?)


  • Reboot Mac and choose USB drive from rEFIt menu


  • USB drive is ignored and the machine boots straight into Windows



In fact, the only way to boot Windows Setup again on this computer is from an external DVD drive, with a Windows 7 DVD in it. Selecting the DVD in rEFIt boots the DVD. Selecting the USB drive (if both are plugged in) also boots the DVD.


Removing the Boot Camp partition from the Mac makes the USB drive bootable again. It seems that whatever bootloader code is executing either from the EFI or from the USB stick tends to prefer any bootable DVD or Windows HD partition over the USB drive. If none are present (DVD unplugged, Windows partition removed) the USB stick boots.


I realize it's an esoteric problem and the DVD workaround is kind of acceptable (even though a PITA), but I'm curious if anyone has an explanation.


(Please don't migrate this to the Apple site. This is not an Apple-only question.)

ASUS laptop doesn't charge/use the battery after reinstalling Windows 7




I've done a clean install of Windows 7 x64 on an ASUS X501A laptop. The battery is detected and shows in the system tray as "plugged in, charging". However the charge level stays at 76% and if the AC cord is plugged out the laptop turns off. The laptop does not turn on without being plugged in either. Everything worked perfectly prior to reinstall.



I've tried:




  • Downloading and installing all the ASUS drivers, including the ATK ACPI driver

  • Checking the BIOS - there do not seem to be any battery-related settings

  • Flashing the BIOS to the latest version

  • Uninstalling Microsoft ACPI-Compliant Control Method Battery in device manager as suggested on the internet

  • Full power discharge/ATX reset as suggested by ASUS support: remove mains power charger, remove battery, press and hold power button for 10 seconds, reconnect battery and mains and turn on




I have a feeling all this may have something to do with the EFI BIOS that comes on the laptop. During the reinstall I had to delete all partitions and start anew, because the Windows installer complained about the improper order of GPT partitions. The EFI System Partition was recreated by the installer, and I am guessing that it may be missing the particular ACPI driver needed to make the battery work.



I've tried researching this, but could not come up with any useful info. I am hoping someone here may know a bit more about this and maybe help me understand what's going on and how to fix it. Barring that, I'll have to re-image the drive off an identical ASUS laptop with stock install and hope it fixes things.


Answer



The fact that the system cannot even turn on from power off without the cord plugged in tells me that the battery hardware is most likely the culprit. You see, the operating system, the hard drive, EFI, all of this occurs way after the BIOS itself performs basic hardware initialization during very early boot. If the battery cells themselves and the connector between the battery and system are intact, then it could be a battery firmware bug.



Certainly it is plausible that there could be battery charging or capacity reporting bugs in the operating system after boot, but these types of problems cannot manifest, by definition, during the stage of boot where the operating system plays NO role whatsoever -- during BIOS initialization.




If fans don't spin / screen backlight doesn't light up / BIOS loading screen do not display when you press the power button with the AC removed, then the battery itself is likely damaged. Or, much less likely, a BIOS update broke it. This is so unlikely because they test BIOS firmware a lot before pushing it to customers, and everyone else would be complaining about the same problem.


Are laptop power adapters Interoperable?


Let's consider two AC power adapters from different brands (e.g. one from HP and another from Dell), with identical electrical specifications (voltage, power) and of course with similar plugs. Would such adapters be interchangeable, i.e. would the HP adapter power the Dell laptop, and inversely ?


Behind this question : is there some kind of data exchange between modern adapters (smart adapter ?) and laptops that enable a laptop to recognize the make of the adapter ? If so, what kind of networking is used, and is it possible to hack it ?


Answer



With an identical connector, equal voltage and at least the same max amperage, with no special gimmicky charger communication, sure.


In reality though, most manufacturers will have their own connector styles, and whilst most are 19v, some are .5 increments above or below.


Regarding the Dell charger communication, yes, basic information is passed using (in some cases, I can't speak for all) the 1-Wire protocol, which has been reverse engineered as can be seen here.


Several generic brands of charger exist, usually with a slider to select the correct voltage and several different tips to connect to the laptop. These usual don't include this communication and can cause problems such as not powering the machine or not charging the battery, although they would actually be capable of doing so without this communication.


compression - really compress a PDF file

I'm trying all the online solutions that promise to compress a pdf file.
It is a scan of 13 pages with a file size of 3.52 MB. Nothing works!


I also tried Adobe Acrobat DC, but this pdf file doesn't seem to apply any compression. I would at least know the reason.

partitioning - Windows 7 system left in unusable state after moving system partition



I tried doing some PC maintenance on my home computer last night, and hosed it up.



A couple years ago i installed a 120GB SSD in my PC. I partitioned it into two equal partitions, the first being my system drive for Windows Server 2008 R2 and the second my Windows 7 system drive.



However, I soon decided that I did not have enough usable space, so I went back to using a HDD as the system drive for my 2008 machine, and continued using the 2nd partition of my SSD as the system drive for my Win 7 install.



I finally decided that I wanted to expand the Win7 partition to use the whole drive.




Since expanding a partition to the "left" is not possible from the Windows disk maangement tool i used GParted to copy the 2nd partition onto the first, then deleted the 2nd partition.



I then I had to use my win7 installation disc to repair windows startup.



Unfortunately, now Win7 boots in an unusable state.



It boots to the login screen ok, but after I authenticate explorer fails to launch leaving me with a blank blue background. If I try to run explorer.exe from task manager i get an error.



Can I recover from this without reinstalling Windows?



Answer



I ended up reinstalling Windows. Of course, I copied my data to a different drive first.


windows - How can I remap a keyboard key?


One of my laptop's keys has fallen off. Is there any way I can remap another key to serve as that key? I'll 'sacrifice' the other key because I never use it.


Answer



Here is a good article from Howtogeek about using a utility called SharpKeys:



Map Any Key to Any Key on Windows 10, 8, 7, or Vista


If you are tired of the way certain keys on your system work, such as the Caps Lock key, you can re-map them to function as a different key by using a registry hack. But there should be an easier way, right?


This is where SharpKeys comes into the picture: It’s a small utility that will let you easily map one key to another key easily, or even turn the key off, without having to enter the registry at all.


For instance, I used the key mapping to just turn off my Caps Lock key, since I never use it.


image


You can click the Add button to bring up the Add New Key Mapping dialog, where you can either select the keys to map from the lists, or just click the Type Key button and press the key manually (which I find much more intuitive)


image


Once you are done, click the Write to Registry button and you’ll be told to log off or reboot for the changes to take effect.


image


If you want all the technical details on how the registry keys work, you can read about how to map keys using registry hacks.



Link for reference


windows - How to remap special keys on my keyboard






I have a mute button on my keyboard, which I use a lot. I also have three buttons I never use...Internet...Email...Search. Is there a hack that a novice user like me can do to get one of those three useless buttons to put my computer into "standby" mode?


Answer



Okay I found it!


Here(archived), is all what you can find about key remapping. Keytweak(archived) work fine for me, is a free keyboard remapper for Windows NT/2000/XP/Vista/Win 7. It makes use of Microsoft's Scancode Map registry key to remap your keyboard.


alt text


This thing lets you remap one of your Internet / Email or Search keys to a sleep key !


It may not work for your keyboard model, make sure you have the latest driver.


data validation - Multi-value selection in an Excel cell


There's a way to make an Excel cell kind of a dropdown selection box. You would just go to Data->Validation with a cell or a range of cell selected, select list as the data type and specify the list of values.


I would like the dropdown be a multi value select, kind of a multi value lookup.
I suppose there's no built in support for that, but there may be some third party solutions utilizing the macro capabilities. Googling gave me an example of such a macro but it is far from the experience of a real multi value lookup when you just mark the selected items with check boxes to the left or select the values in a kind of a popup window. (You would select the items needed from a single-value dopdown ny sequentially selecting each item and the macro would populate an adjacent range of cells with the selected values, putting every value in a new cell).


What's is the most native looking way to make a multi-selection cell in Excel?


Answer



See the Forms section in Excel Help for the topic "Add a list box or combo box to a worksheet".


From that page (referring to a Form control list box):



Note: If you set the selection type to
Multi or Extend, the cell that is
specified in the Cell link box returns
a value of 0 and is ignored. The Multi
and Extend selection types require the
use of Microsoft Visual Basic for
Applications (VBA) code. In these
cases, consider using the ActiveX list
box control.



And referring to an ActiveX control list box:



To create a list box with multiple
selection or extended-selection
enabled, use the MultiSelect property.
In this case, the LinkedCell property
returns a #N/A value. You must use VBA
code to process the multiple
selections.



Tuesday, June 27, 2017

Specific tip to remove one type of telemetry from Windows 7

Much has now been written about removing telemetry from Windows 7.


But one recommendation I don't find often is from the useful website AskVG.com:



Our reader "Xircal" shared some useful information with us. Even if the user opts out of the CEIP program, another task called "Microsoft Compatibility Appraiser" continues to relay data to Microsoft via a log file called "AutoLogger-Diagtrack-Listener.etl" present in "C:\ProgramData\Microsoft\Diagnosis\ETLLogs\AutoLogger\" folder.


You can disable this Compatibility Appraiser task using following steps:



  1. Press WIN+R keys together to launch RUN dialog box, type regedit in RUN and press Enter. It'll open Registry Editor.


  2. Now go to following key:


    HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\WMI\AutoLogger\AutoLogger-Diagtrack-Listener


    In right-side pane, change the value of Start DWORD to 0 to turn off the auto logger program.


  3. Again go to following key:


    HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\WMI\Autologger\AutoLogger-Diagtrack-Listener{DD17FA14-CDA6-7191-9B61-37A28F7A10DA}


    In right-side pane, look for the DWORD Enabled. Its value would be set to 1 by default. Double-click on the DWORD and change its value from a 1 to 0 to disable the task.



Restart your computer to take effect.



Besides not contributing to Microsoft's massive volume of collected data, are there any downsides to following this tip? Does it break anything (except sending telemetry data to Microsoft)?

High disk usage windows 8.1


i already read a lot of about 100% disk usage(50% because i have second disk) on windows machines but nothing help me. I figured out that i need to stop svchost.exe and ntdll.dll in it. Hovewer when i stop this service network stop working for some time and killing srervice dont solve my problem. I already update windows, disable prefetch. You can see service on image.


HW: intel i7 4710HQ, 256GB SSD, 16GB RAM OS: Windows 8.1 x64



ETL file:


https://drive.google.com/file/d/0B8j7G6Ql6xXvekJLQU9IU0ZaanM/view?usp=sharing


Answer



Checkin the trace for CPU usage, I can see that the CPU usage comes from srumsvc.dll!SruWorkQueueThreadPoolCallback which later calls some esent.dll functions.


enter image description here


SRUM stands for "System Resource Usage Monitor".



Windows 8 and Windows 10 has a newly added feature to track system
resource usage, specifically process and network metrics over time.
Process related information such as process owner, CPU cycles used,
data bytes read/written, and network data (sent/received) are
continuously recorded by a mechanism called System Resource Usage
Monitor (SRUM).



This is a component which is part of the Diagnostic Policy Service. Watch the video and read the linked PDF for a detailed look what the System Resource Usage Monitoris.


Checking the trace for DiskIO, I see that the disk IO happens to file C:\Windows\System32\sru\SRUDB.dat which is the database of the SRUM service which also explains the ESET Database calls, which cause CPU usage.


enter image description here


So, if you don't use metered connection or want statistics about network, CPU usage in Taskmgr you can try to disable the Diagnostic Policy Service.


Change administrator password on windows 7 with autologon without knowing the old one

I have a Windows 7 machine that is set up with automatic logon. It is an internal machine not reachable by anything so security isn't an issue.


I don't remember what the password is, but in order to install some some software that will run as a service I need to input the current password.


The question is, how can I change the password on the administrator account without knowing the current password? Note that since it is set up with automatic logon, I have full access to the machine, but both Ctrl+Alt+Del change password and the control panel user manager change password requires the old password before changing.


Is this possible?

How can you make Excel 2007 stop formatting large numbers as scientific notation?


Kind of the inverse of this question.


I frequently download CSVs from outside sources as part of my programming work. I like to examine their data in Excel because, let's face it, Excel is an ideal tool for this sort of thing.


Except for one behavior: Excel attempts to outwit the data in the CSV, and therefore, if something looks like a number (like, say, many ISBN/EAN codes), Excel will treat it as such. And if this number is really big (like pretty much all ISBN/EAN codes), Excel will turn the number into scientific notation. Finally, if the number isn't particularly big, with most of these data formats, that indicates that Excel has decided that my number shouldn't have leading zeroes.


So ... Is there a way to open a CSV (via double-click if possible, but I'm willing to compromise here) in such a way that I can have Excel 2007 treat all the columns as text?


Answer



You can, but it takes a couple of manual steps. These steps are from Excel 2003, but I'd assume the wizard is similar in 2007:



  1. Rename the file as TXT. Don't double-click it.

  2. Open Excel

  3. Click File, Open

  4. Locate and double-click the text file

  5. It should open a "Text Import Wizard"

  6. In step one, choose "Delimited"

  7. In step two, uncheck "tab" and check "comma"

  8. In step three, scroll-over to the last column, shift-click to select all columns, then click "Text" as the format.

  9. Ignore the annoying "Number stored as text" warnings everywhere


Goes pretty fast with some practice.


Is it safe to add the third wire on Dell Laptop charger to an external battery?


I wired an old secondhand Dell charger (that was making a funny noise when charging), to the laptop 19v output of a RocketSocket charger. It works great, but there's one problem... it shows charging, the battery doesn't go down, but it doesn't actually charge the laptop battery, and when I start up the computer it gives that infamous adapter not recognized message.


Now, I suppose I could cut open the charger and wire the chip to the third wire, but I think that may be a bad idea because according the the instruction sheet, the RocketSocket outputs 12/16/19V - 2/3.5/3.5A output. The secondhand Dell charger shows output 19.5v 4.62A. Do I risk overheating or damaging the RocketSocket laptop charger or the Dell by faking a more powerful adapter's chip? Or can I reprogram the third wire's chip to set the correct expected amperage?


Answer



As I understand the specs for "Rocket Socket" charger, it can do 12V with 3.5 A, but at 19V it can do only 2 A.


So yes, if you attach the Dallas ID chip from Dell 19V 4.62A adapter to the center wire, the laptop will think that it has the PA-10 power adapter, and will try to suck up to 4.62 A, thus overloading the "Rocket-Socket" by more than twice. The likely effect will be either the voltage will drop below 10V, or it will smoke out. The advice - don't do this, or get a more powerful power supply.


But again, why go for such a trouble if the original DELL 90W 19V/4.62A adapters are well under $10 even on Amazon?


Regarding programming or emulaing the ID chip, there were some attempts to do so. But again, does the trouble worth it?


Monday, June 26, 2017

motherboard - Is using a 3200MHz DDR4 Memory O.C.?


I was selecting the parts for a new Server when i read in the specifications of the motherboard (Gigabyte Z170 Gaming 5) this:



Support for DDR4 3466(O.C.) /3400(O.C.) /3333(O.C.) /3300(O.C.) /3200(O.C.) /3000(O.C.) /2800(O.C.) /2666(O.C.) /2400(O.C.) /2133 MHz memory modules



Since the RAM i selected is a Corsair Vengance Lpx DDR4 8GB 3200mhz (two cards) i was wondering if this counts as OC for this motherboard and if its safe to install them.


I was also wondering if there would be much difference with 2133 modules? The server will be running a program that copies files to ram, process them and copies them back to disk.


I'm also buying an Intel I7 6700.


Thanks in advance!


Answer



It means that the motherboard natively supports RAM @ 2133MHz, and if you mount a higher speed RAM (@ 3466, 3400, 3333, 3300, 3200, 3000, 2800, 2666, 2400MHz) that motherboard will still run it @ 2133MHz. However, in this case, you can overclock it to use it at full speed.


For example, mounting your 3200MHz RAM would mean that it will still run @ 2133MHz, unless you decide to overclock it up to 3200MHz.


It is safe to overclock your RAM to that speed if it natively supports it (which is your case), although the best thing you could do is to run some benchmarks and test the performance of your server when the RAM is OCd and not, to see if it's worth it. Also remember that overclocking the RAM will result in higher CPU temperatures, so check on them and be sure to have a proper cooling system.


windows 7 - How to create a file with invalid or special characters in its name?

I'm trying to install some Python 2.7 module named libwapiti on Windows 7. While trying to install it, it asked me for several header (*.h) files which were not included in MSVC2008ForPython27 and I'm trying to fix it.




Right know it asked for a file named: sys/time.h I copy-pasted the code inside a text file but when I try to rename it to what mentioned above, Windows says you can't create a filename with /\?*<>| and so on. What can I do?!

Hard disk noise under linux gets smaller when partitioned



I just bought a Toshiba X300 8TB 7500r hard disk.



At first I used the whole disk as a partition, the noise is really intolerable.




Then I tried to use a small partition of 1TB or 2TB, the noise is much smaller.



But 4TB still produces a large noise.



Can anybody give me some hint? Why partition size affects noise level?



Thank you very much!



Update:




A more recent test shows that, the partition size may not be the key reason for the noise.



The noise is generated when the ext4 performs [ext4lazyinit] at a speed of 5MB/s.



After I remount the disk with init_itable=0 option, the [ext4lazyinit] can perform at a speed about 100MB/s, the noise is gone!


Answer



The linux default filesystem, ext4, spreads files as far apart as it can to help against fragmentation (so you don't need to defragment so often). The side effect is that your HDD heads will travel a lot. You could try another file system like exFAT if that's acceptable.



For more information, see Do ext4 filesystems need to be defragmented?



partitioning - Windows can't read a hard drive partition

My issue is with my external hard drive, which was doing fine until not so long ago. It stores 200 GB, and is a good old 3,5" (I took it from my previous desktop, and put it into an external case that has a USB interface).


This hard drive has 2 partitions, and in December, I thought I'd rename one of the partitions (without changing anything else). I then moved some files around from one partition to the other, and at some point the partition I had renamed went rogue: Windows cannot access it anymore.


The other partition is fine, all files are in place and can be accessed normally. The first partition exists: Windows can see it's there, but not recognize its name, nor access any content. I tried a tool that looked into the file structure of the partition and recognized that the folders were there, so I assume that those file are still there, but Windows can't get there.


My hunch is that something happened to the "name" of the partition, and now Windows can't access the rest of the files.


Is there a tool I can use to "rebuild" the 'heading' of the partition? If possible, I'd rather not lose the contents of that partition by reformatting it.


In summary, I need a hard drive partition tool or something like that that could fix whatever went wrong with the partition.


Thanks in advance for the advice.

Sunday, June 25, 2017

virtualization - Can't Access Google Cloud Compute VM Instance using external IP

I have set up and enable a VM to Allow HTTP traffic and Allow HTTPS traffic but i cannot access the external IP in a browser. Im using the VM for web development testing and need to see changes made. The external IP address is listed as (ephemeral) but from what i've read, all this means is that the IP will not persist through shutoff/restart.

windows 7 - Uninstall laptop screen, replace with external monitor

So as the title states, I took off the display panel on my Dell N4010 and replaced it with an HP LE1901w external monitor because I didn't feel like purchasing a $50+ LCD screen (Got the monitor for $9 at Goodwill). I also removed the CD Drive (don't ever use it) and placed the WiFi antenna where it was located, but that works well. ([picture][1])


Anyways, because I did that, a few problems came up.


First, when I boot up my laptop, it does 8 consecutive beeps and then starts over to warn about display failures, even though I have the external monitor hooked up. Is there any way to turn this off? I've checked the BIOS settings and I don't see anything about any chimes, beeps, or default displays.


Also, the "Starting Windows" splash screen is off center, as well as the BIOS some times. Auto-Adjusting the monitor only helps with the BIOS, but the splash screen still pushes to the left. It's very noticeable and I wanted to know if there's a fix for it.


Finally, my computer still recognizes the laptop's built in display. I've tried disabling it in the device manager, but I wasn't able to get a permanent fix. For the monitor to work properly, I have to enable the "Projector only" display setting with the F2 Key or the graphics options. Is there any way to completely uninstall the laptop's monitor? Even my Linux install recognizes the laptop's monitor.


One last thing, it would be nice to control the monitor's brightness with the laptop's brightness keys. I know I can control the monitor's brightness along with other settings with the Intel Graphics Properties ([picture][2]),


so I don't think it should be too hard to re-configure the keys to do the same.


I'd really appreciate a some suggestions. If you need any more information, just ask.


EDIT: New problem just popped up, GRUB2 is off center as well and auto-adjust doesn't help

hdmi - Dual Monitor setup issues between laptop and external led monitor

I have two challenges.



  1. Monitor will not connect to laptop through HDMI

  2. Watching HD video content causes the laptop to sometimes turn off expecially when I'm streaming from tekzilla.com


Setup.


I got my new HP 2311x LED LCD monitor this week and I have it running as the main monitor extended by the 15 inch screen on my Dell Studio 1558. Right now I have to connect the external monitor through VGA.



  • For the HDMI connection issue. I suspect that either the appropriate drivers are not installed because I don't see any hdmi device in the device manager. I've checked and I don't see any hdmi specific drivers listed online.


  • For the shut down issue, I suspect the laptop might be overheating. Not sure why it would. It never did that while I watched movies on my laptop's default screen.



My Laptop Configuration:



  • 15" led lcd screen at 1366 x 768


  • intel i5 processor


  • integrated graphics card


  • 4 GB DDR3 RAM


  • 500 GB hard drive



I've tried everything from switching the source on my monitor to hdmi to start up combinations and nothing has worked.


What could be the issue and how do I solve it?

bsod - Blue screen after Windows 7 login, "Driver Irql Not Less Or Equal"


This occurs just after I log into Windows 7 Home Premium.


Does any body what this means and how to resolve the issue?


Answer



This is likely a malfunctioning driver activated as it occurs after login, or do you experience randomness?


Please read this article to troubleshoot your BSOD, try to see if Safe Mode works and check the Event Log.


If you can get there, please upload the dump file so we can analyze for you which driver did this.




Edit:


Not checking the crash dump is trying to fix a problem without knowing what the problem is.


So, you can try to remotely obtain the crash dump file, it is located at one of these two paths:



  1. C:\Windows\MEMORY.DMP


  2. C:\Windows\Minidump\*.DMP



The best way would be to connect the hard drive to another computer...




Edit 2:


The driver that is crashing your computer multiple times is mfehidk.sys, from McAfee, your virus scanner.


SYSTEM_THREAD_EXCEPTION_NOT_HANDLED_M (1000007e)
This is a very common bugcheck. Usually the exception address pinpoints
the driver/function that caused the problem.
Probably caused by : mfehidk.sys ( mfehidk+188e9 )

If we list the module, we get:


fffff880`03ab2000 fffff880`03afba00   mfehidk  T (no symbols)
Loaded symbol image file: mfehidk.sys
Image path: \SystemRoot\system32\drivers\mfehidk.sys
Image name: mfehidk.sys
Timestamp: Fri Jul 31 23:59:58 2009 (4A73695E)
CheckSum: 0004F637
ImageSize: 00049A00
Translations: 0000.04b0 0000.04e4 0409.04b0 0409.04e4

It's April 2011 and that driver dates back to July 2009, that's horribly out of date for a virus scanner.


If you can get into safe mode you can try to remove the virus scanner, if not you could attempt to rename C:\Windows\System32\drivers\mfehidk.sys so that the operating system should not load it anymore.


There are ony two dumps mentioning the iastor.sys driver, which is related to your hard disk. This makes sense as either the virus scanner driver or the hard disk driver is accessing memory in such way that the other one can't write to it, as a virus scanner scans files but this one seems to do it too early...


See how both dumps have problems reading or writing the memory:


ERROR_CODE: (NTSTATUS) 0xc0000005 - The instruction at 0x%08lx referenced memory at 0x%08lx.
The memory could not be %s.
DRIVER_IRQL_NOT_LESS_OR_EQUAL (d1)
Arg1: 00000000000007e1, memory referenced
Arg3: 0000000000000001, value 0 = read operation, 1 = write operation
Arg4: fffff8800112a4ff, address which referenced memory

So, the steps to take are:



  • Prevent the virus scanner from loading, with either safe mode or by renaming the driver.


    This will verify if the virus scanner is the culprit.


  • If it's not the virus scanner, do a error scan on your memory and hard disk.





Edit 3:


As you are crashing on the iastor.sys only now, I've looked at its date.


fffff880`010ba000 fffff880`011d6000   iaStor    Fri Jun 05 03:53:40 2009 (4A287AA4)

If I look at mine I see this:


enter image description here


So, updating your Intel Rapid Storage Technology drivers might fix your issue.


Uninstall any Intel Matrix RAID and Intel Rapid Storage Technology drivers first if possible...


How to add the Windows defender into Windows Explorer's right click menu to scan a particular drive/folder/file on demand in Windows 8?



There is no option in Windows Explorer to scan a particular drive (or file) on demand by right clicking on it in Windows Explorer as we had in Windows 7 with Microsoft Security Essentials or like other antivirus solutions.



I know we can run a custom scan for the particular drive or specific folder but that process is too lengthy and time consuming. The guide How to Add a "Windows Defender" Cascading Desktop Context Menu in Windows 8 explains how we can add Windows Defender in the desktop right click menu, so I'm curious, is there a way to add it in the Windows Explorer right click menu to launch a search whenever I need to?


Answer



Avirk's answer actually doesn't scan a file or folder directly, it just initiates a quick or full scan of your entire computer.



http://www.thewindowsclub.com/add-scan-with-windows-defender-option-context-menu-windows-8 outlines a method to get the scan to work on folders. I think with some modifications it can be made to work on files as well.




UPDATE:
It is fairly easy to get this to work on files, just change the /folder/ part of the registry keys to /*/.



Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\*\shell\WindowsDefender]
"MUIVerb"="Scan With Windows Defender"
"Icon"="%ProgramFiles%\\Windows Defender\\EppManifest.dll"
@=""

[HKEY_CLASSES_ROOT\*\shell\WindowsDefender\Command]

@="\"C:\\Program Files\\Windows Defender\\MpCmdRun.exe\" -scan -scantype 3 -SignatureUpdate -file %1"


(Just paste the above in a file with extension.reg and merge it into the registry by double-clicking the file.)



The one thing I can't get working is bringing up the GUI scan versus a console version of the scan output.


Saturday, June 24, 2017

Hotkey with simple colon ":" autohotkey




Why my script isn't working ?



<^>!:::
{
MsgBox You pressed AltGr+:
Return
}

Answer



What kind of keyboard layout do you use? If I want to get to :, I have to use Shift+;.




I can't use RAlt on my PC, but this works for me with the LAlt key:



!+`;:: ; Use + to shift the [;] key into [:] and use a back-tick [`] to literally interpret the next character.
{
MsgBox You pressed [LAlt]+[:]
Return
}

command line - using "runas" with "Administrator" account versus other admin accounts

On my computer, I have two admin accounts. The default admin account named "Administrator", and a new admin account named "testadmin."



If I run the following commands:




runas /user:testadmin cmd.exe
runas /user:Administrator cmd.exe


The first one opens up a new cmd.exe as "testadmin", but it's not truly running in Administrator mode, i.e. I get "Access denied" if I try to write to C:\Windows.



The second window opens up a new cmd.exe as "Administrator", but it's running in true Administrator mode. I can successfully write to any folder on my computer.



The name of the first window is "cmd.exe (running as [ComputerName]\testadmin)"




The name of the second window is "Administrator: cmd.exe (running as [ComputerName]\Administrator)"



If both accounts have admin privileges, why is there a difference in behavior here? I hate that I can't open a window from the command line as testadmin in true Administrator mode... it's really annoying.

Sony Vaio dekstop wireless keyboard won't type certain keys

I cannot type certain keys, p, m, return, couple of others. I have made sure localization and keyboard settings are correct. I have removed and installed new batteries, also tried just leaving them out. I have tried a myriad of key combinations to reset the keyboard (both shift keys, control, alt, etc.). Nothing has worked. Num lock is not on, no function keys are on. No keys are stuck.




Other keyboards work. The keyboard in question was working fine 12 hours earlier.



This is a desktop all in one Sony, not a laptop.



Any ideas? Thank you.



EDIT: Nothing has been spilled on the keyboard. No keys are stuck.

Friday, June 23, 2017

How to edit Chrome web shortcuts to add 'Rating', 'Description' and 'Notes' in Windows File Explorer?



I add web shortcuts from chrome to Windows (8.1) File Explorer into different folders so that I can access not only the downloaded documents but also the ones I want/need to check online.
But I'd like to edit their properties the same way I do with other files like .docx and .pdf (so that I can display these properties in"details view" and/or search for them). It is pretty convenient and straightforward; the properties for Chrome and Firefox shortcuts are right there just right-clicking on the shortcut, clicking properties \ Details Tab. There you'll see the properties 'Rating', 'Description' and 'Notes' which you "can" edit right there (Internet Explorer doesn't show these editable fields):



Details tab



Almost. Because when you try to apply the changes (pressing 'OK' or 'Apply' buttons), it will ask you (at least me) for Administrative privileges:




File Access Denied





...which I try to apply ('Continue' button) but:



Provide Permissions




Then I go to the specified folder to give this user (highlighted in blue in the pic) more permissions but it already has 'Full control' as you can see below. There's no way (or I can't find it) to add more permissions (like Special permission, the only one which is not ticked under 'Allow', and/so I'm not sure it would actually help.



Already have Full control



Does anyone have any idea of how could we modify these Chrome/Firefox shortcut properties so that we can display and/or search for them in Windows File Explorer?


Answer



How do I edit Chrome web shortcuts to add 'Rating', 'Description' and 'Notes'?



There is a bug which prevents you making the changes you want in the way you have described.




I've tested the workaround below with a Firefox shortcut. It should work for Chrome shortcuts as well.






Apply Property Error" occurs when attempting to modify either the Ratings, Description or Notes fields of a Favorite shortcut




Microsoft has confirmed this to be a problem with Microsoft Windows 7 including Microsoft Windows 7 with Service Pack 1.



WORKAROUND




The issue can be alleviated by manually editing the shortcut URL in a text editor such as notepad.exe. Simply copy and paste the desired setting i.e. Description Field, Notes fields and Ratings Field.



enter image description here



DESCRIPTION FIELD



[{5CBF2787-48CF-4208-B90E-EE5E5D420294}]

Prop21=31,<<< Add Description Field Text Here >>>



For the Description and Notes Fields the text will need to be manually
edited. The Description field outlined in Indigo in the image above.
To add description text, start to the right of the comma after
"Prop21-31" (replacing <<< Add Description Field Text Here >>>
highlighted in Red in the image above with the desired text).



NOTES FIELD




[{B9B4B3FC-2B51-4A42-B5D8-324146AFCF25}]

Prop5=31,<<< Add Notes Field Text Here >>>


Likewise, the Notes Field outlined in Green in the image above will
also need to be manually edited. To add text to the Notes field,
start to the right of the comma after "prop5=31," (replacing <<< Add
Notes Field Text Here >>> highlighted in Red in the image above with
the desired text).




For Star Ratings, all that is needed is to copy and paste the desired
value i.e. 1 star, 2 star, 3 star, 4 star and 5 star



(Note: a 5 star rating was copied in the sample image above).



1 Star:



[{64440492-4C8B-11D1-8B70-080036B11A03}]


Prop9=19,1


2 Star:



[{64440492-4C8B-11D1-8B70-080036B11A03}]

Prop9=19,25



3 Star:



[{64440492-4C8B-11D1-8B70-080036B11A03}]

Prop9=19,50


4 Star:



[{64440492-4C8B-11D1-8B70-080036B11A03}]


Prop9=19,75


5 Star:



[{64440492-4C8B-11D1-8B70-080036B11A03}]

Prop9=19,99




Source "Apply Property Error" occurs when attempting to modify either the Ratings, Description or Notes fields of a Favorite shortcut on Windows 7 with either Internet Explorer 8 or 9






Notes on the workaround



Replace the shortcut file with the edited file:





  1. Start run "notepad"

  2. Drag and drop shortcut onto notepad.

  3. Make changes as required and save file.

  4. Change explorer details view to show appropriate columns



Take care not to delete existing lines but just add the new ones you require.


windows 8 - Shortcut Keys Issue

I created some custom keyboard shortcut keys for some of the file shortcuts,
But after I deleted above mentioned file shortcuts, I cannot assign the keyboard shortcut keys associated with old ones to any new file shortcuts,
How do I fix this?
Also is there any application available that shows all the current assigned keyboard shortcut keys?
Thank you

formatting - Format PC without losing Windows 7 license






I have a windows 7 intallation that I got from MSDN. The thing is that I want to format my PC and reinstall windows 7.


At first I thought I just have to write the current key somewhere, reinstall windows 7 normally and then activate it with my old key, but a friend did this and on the last step the activation wouldn't work because it said that the key was in use.


What can I do?


Answer



It may work just fine but if not, you simply need to call the Microsoft number the activation tool will give you and explain the format and reinstall. Takes a few minutes.


Thursday, June 22, 2017

Wednesday, June 21, 2017

networking - How to block all traffic but one IP in windows firewall using command line

I have a project and for it I need to only allow connections in from a certain subnet, everything else must be dropped. The catch is that its all going to be automated, no user interaction, there for the other answers showing how to use the GUI in windows are no good. I have a Python script that runs the windows shell command (netsh advfirewall...) that makes all the rules I want, however if I add a block all rule it overwrites all my allow rules. I tried adding it first as well as last on the list of rules, I'm not sure what I'm doing wrong. Attached are my commands/rules




import subprocess

#allow connections over port 80 and 443 tcp
subprocess.call('netsh advfirewall firewall add rule name="allow port 80 tcp in" dir=in localport=80 protocol=tcp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 80 tcp out" dir=out localport=80 protocol=tcp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 443 tcp in" dir=in localport=443 protocol=tcp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 443 tcp out" dir=out localport=443 protocol=tcp action=allow', shell=True)

#allow icmt v4/v6 in/out

subprocess.call('netsh advfirewall firewall add rule name="allow port icmpv4 in" dir=in protocol=icmpv4 action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port icmpv6 in" dir=in protocol=icmpv6 action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port icmpv4 out" dir=out protocol=icmpv4 action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port icmpv6 out" dir=out protocol=icmpv4 action=allow', shell=True)

#allow ssh (port 20) via specific subnets
subprocess.call('netsh advfirewall firewall add rule name="allow port 20 in" dir=in localport=20 remoteip =10.0.0.0/8 protocol=tcp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 20 in" dir=in localport=20 remoteip =192.168.0.0/16 protocol=tcp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 20 in" dir=in localport=20 remoteip =172.0.0.0/8 protocol=tcp action=allow', shell=True)


subprocess.call('netsh advfirewall firewall add rule name="allow port 20 out" dir=out localport=20 remoteip =10.0.0.0/8 protocol=tcp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 20 out" dir=out localport=20 remoteip =192.168.0.0/16 protocol=tcp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 20 out" dir=out localport=20 remoteip =172.0.0.0/8 protocol=tcp action=allow', shell=True)

#allow rdp (port 3389) via specific subnets

subprocess.call('netsh advfirewall firewall add rule name="allow port 3389 in tcp" dir=in localport=3389 remoteip =10.0.0.0/8 protocol=tcp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 3389 in tcp" dir=in localport=3389 remoteip =192.168.0.0/16 protocol=tcp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 3389 in tcp" dir=in localport=3389 remoteip =172.0.0.0/8 protocol=tcp action=allow', shell=True)


subprocess.call('netsh advfirewall firewall add rule name="allow port 3389 out tcp" dir=out localport=3389 remoteip =10.0.0.0/8 protocol=tcp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 3389 out tcp" dir=out localport=3389 remoteip =192.168.0.0/16 protocol=tcp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 3389 out tcp" dir=out localport=3389 remoteip =172.0.0.0/8 protocol=tcp action=allow', shell=True)

subprocess.call('netsh advfirewall firewall add rule name="allow port 3389 in udp" dir=in localport=3389 remoteip =10.0.0.0/8 protocol=udp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 3389 in udp" dir=in localport=3389 remoteip =192.168.0.0/16 protocol=udp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 3389 in udp" dir=in localport=3389 remoteip =172.0.0.0/8 protocol=udp action=allow', shell=True)

subprocess.call('netsh advfirewall firewall add rule name="allow port 3389 out udp" dir=out localport=3389 remoteip =10.0.0.0/8 protocol=udp action=allow', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="allow port 3389 out udp" dir=out localport=3389 remoteip =192.168.0.0/16 protocol=udp action=allow', shell=True)

subprocess.call('netsh advfirewall firewall add rule name="allow port 3389 out udp" dir=out localport=3389 remoteip =172.0.0.0/8 protocol=udp action=allow', shell=True)

#Block all connections
subprocess.call('netsh advfirewall firewall add rule name="block all inbound" dir=in protocol=any action=block', shell=True)
subprocess.call('netsh advfirewall firewall add rule name="block all outbound" dir=out protocol=any action=block', shell=True)

ntfs - Laptop HDD fail, Shows partition but can not copy data, testdisk MBR code fail

I use 2TB HDD in my laptop with 250 GB partition for windows 10 and rest for data storage. I switched my laptop so moved the HDD from old to new laptop and started the system. Windows logo came up but within a minute laptop crashed and then after nothing worked. I took out the HDD and plugged externally to another windows 10 system where it shows both the partition mounted with their respective sizes. When I open the drive it shows folders as well but when I open or copy any of the folder it gives error "The device is not ready".


I tried using minitool and recuva data recovery but it failed to detect anything.


Then I plugged the HDD externally to Ubuntu system. Gparted shows 3 partitions, 1) ntfs system reserved 549 MiB, 2) ntfs Windows 250 GiB, 3) ntfs 1.57 TiB. But the direct data copy or testdisk fails.


I used testdisk to analyse lost partitions but nothing is reported, even in deep search. I then used the MBR code but even that failed.


I also used gddrescue to copy image the entire disk which ran for ~ 24 hours and made the image file of 800 GB. Following is the output of log:


# Rescue Logfile. Created by GNU ddrescue version 1.19
# Command line: ddrescue /dev/sdb /media/v/Seagate Backup Plus Drive/copy.img /media/v/Seagate Backup Plus Drive/status.log
# Start time: 2018-11-29 12:16:31
# Current time: 2018-11-30 11:33:28
# Copying non-tried blocks... Pass 1 (forwards)
# current_pos current_status
0xC21A8B0000 ?
# pos size status
0x00000000 0xBF655E0000 +
0xBF655E0000 0x00010000 *
0xBF655F0000 0x00010000 ?
0xBF65600000 0x7F078000 +
0xBFE4678000 0x00008000 *
0xBFE4680000 0x00010000 ?
0xBFE4690000 0xA9DC0000 +
0xC08E450000 0x00010000 *
0xC08E460000 0x00010000 ?
0xC08E470000 0xDDADC000 +
0xC16BF4C000 0x00004000 *
0xC16BF50000 0x00010000 ?
0xC16BF60000 0xAE950000 +
0xC21A8B0000 0x2E166F25E00 ?

I have important data in Data partition so I do not want to take risky steps. So I am now posting this question for help.


Update 20181201
I ran ddrescue and following is the current status.
ddrescue status


Any idea why the recent blocks are full of errors? I see a trend that somewhere in middle many red block are coming? Could it be that the rest of the blocks will follow the same trend henceforth? How do I see which files have been rescued in the green area?


Kindly suggest how to rescue the data on the disk.


Thanks a lot in advance.

battery - plugged in, not charging

My acer aspire r7 won't charge and it states "plugged in, not charging." Looks like this is a fairly common problem people are having. I have tried many suggested solutions that I I found researching and nothing has worked yet.



There is the "12 step" solution which seems promising:




  1. Disconnect AC adapter

  2. Shutdown Windows 8

  3. Remove battery

  4. Connect AC Adapter

  5. Power on the laptop


  6. Open the Control Panel and select Device Manager

  7. Under the Batteries category, right-click all instances of Microsoft ACPI Compliant Control Method Battery , and select Uninstall, even if you have only one (I had two, as shown in figure 1 below)

  8. Shutdown

  9. Disconnect AC adapter

  10. Insert battery

  11. Connect AC adapter

  12. Power on the laptop



The problem for me with this solution is step 3 which requires you to remove battery and my laptop has an internal battery. I tried doing all the other steps and no luck. Any suggestions would be very much appreciated. Thanks so much, Abbi

memory - Why PCs need much more RAM than video game consoles to run the same games?



It seems strange to me that every 7th generation console has much less memory than contemporary PCs, but games on consoles still run pretty smooth today.



For example:
PS3 has 256 MB memory for system and 256 MB memory for video.
Xbox 360 has 512 MB of GDDR3 RAM clocked at 700 MHz.
And, this is really strange, Wii has only 24 MB of video RAM and 64 MB GDDR3 system RAM.




But if you try to run GTA 4 on the PC with 256 MB of system RAM, even with 256 MB RAM on the video card, well, let's just say it won't work that way.



Why?


Answer



Let's do some comparisons...




PS3 has 256 MB memory for system and 256 MB memory for video. Xbox 360 has 512 MB of GDDR3 RAM clocked at 700 MHz. And, this is really strange, Wii has only 24 MB of video RAM and 64 MB GDDR3 system RAM.





Graphics on Wii games are usually kept simple, you won't see shiny graphics there apart from the nice intro to Mario & Sonic's introduction screen. Although that's just a video playing back, cheap...



If you don't believe me, this comparison shows it clearly.





A Visual Comparison Of Modern Warfare's Wii Debut And The Original



It doesn't seem easy to find other clear comparisons, the image search results are overloaded with results of the same game, the Wii U or pictures too small to tell the difference; you're always welcome to add another picture, but the Wii game console has yet to surprise me.




For the PS 3 vs XBOX 360, you clearly see a difference in texture.





Developers Speaking Out on the PS3



As for XBOX 360 vs PC, the difference lies in the resolution, textures and more...






Risen releases February on 360, will be proper port



Is it all about the memory?



No, certainly not. How fast the GPU can perform in terms of fill rate and shading also plays a huge role; this is why the XBOX 360 outperforms the PS 3, as they have the same amount of memory.



All those factors involved in the specifications contribute to being able to do effects like bloom, drawing things further in the distance, do better bump mapping and lightning, having even better AA and more...



Sometimes this takes a second look at the photo to actually see the difference, most often you can't always tell this due to compression of the picture (or YouTube video) such that it doesn't represent the actual graphics in the game.




Similarly, you can get a PC with a ton of memory, but have a card that can't even play a game at 720p.



It's about how much you can put into it for the price.



Let's say price wouldn't matter, well, we'd have something like the Fastra II.





That's right, we're looking at six NVIDIA GTX295 dual-GPU cards, and one GTX275 single-GPU card. That's 13 GPUs total! That's why it outperforms a typical GPU 12 times.






Although, well, yeah; this set-up requires some software / driver optimization to suffice for gaming.



To address the question... Do PCs need much more RAM?



Not necessarily, one could build a machine with a light-weight Linux kernel, light-weight X and perhaps wine as well (unless the game has native support); as a result you'll end up with barely any space taken by the Linux kernel and most space available to the game, then, you get the hardware with the same memory limits as the console, turn down the game graphics and actually have PS3 / XBOX 360 like graphics. I have no clue whether the Wii specs could be achieved, but most games on the Wii aren't available for computer architectures anyway (ignoring emulation).



The PC itself doesn't impose more memory, it's what the environment your game runs in does.



windows vista - How can I reduce the size of the Winsxs folder without damaging anything?






This folder has grown to over 12GB and continues growing in size. Is there any way to clean it up without damaging the installed programs or Vista?


Answer



This folder is essential for all the programs that you have installed. To prevent the "DLL hell", Windows copies required DLLs for every single installed program here. This way, installed programs do not influence each other. It is very common for this folder to grow over 10 GB and beyond.


Try uninstalling some unneeded programs, see if that helps. If you want to keep the folder small, reinstall your Windows and install as few additional programs as possible. But that maybe defies the purpose of having a personal computer at all.


So in short: it is a necessary evil to live with. It is a price we pay for compatibility.


Tuesday, June 20, 2017

windows 7 - How to mount a USB thumb drive as "Fixed" instead of "Removable"

I have over 8 GB in my "Code Library" that I maintain on a 64 GB ScanDisk Ultra Backup USB Device.


Windows Search 4.0 (installed on Windows XP) can index removable drives, but Windows 7 (which uses Windows Search 4.0) cannot, because the USB device identifies itself as a Removable drive and Windows 7 refuses to index removable drives.


How can I mount the USB Thumb Drive as Fixed instead of Removable?

Linux $PATH variables, soft links, and Command Not Found

I am having problems with symbolic links and the $PATH variable.


I have a directory:


# /usr/rulerX/square

where /usr/rulerX/square is a symbolic link such that:


# ls -la
square --> square.hg.current

My path variable is set as:


# echo $PATH
/usr/rulerX/square/bin:/usr/local/bin:/usr/bin

I have a file, runSquare, under /usr/rulerX/square.hg.current/bin/


Here's the problem:


# runSquare
runSquare: Command Not Found

What gives? If I set /usr/rulerX/square.hg.current/bin to the PATH; everything works fine. However, if I have the symbolic link (just 'square'), it can't find the file.



  • I am using CentOS with csh

windows 7 - Proper way to print a shipping label - half letter sheet

I have a shipping label (half letter size) + payment slip / tracking confirmation (another half), printed from PayPal. There is no way to avoid printing of payment slip, using CanadaPost, as far as I know, so it will print the full letter page filled with text.



I thought maybe I can cut the other half with scissors, and just make sure I feed half letter sized paper, but not sure how it will impact printer and toner yield. Will it start printing where there is no paper (expecting full letter sheet) and then I end up having toner all over printer interior?



Question: Is there any way I can print only the first half of the page, i.e. actual shipping label and don't print the other half? I would prefer a clean / software solution, if such exists.



What I have tried so far




  • Print from my browser, with headers disabled and minimum margins. It prints both halfs, shipping label fits on the first, other half is wasted.


  • Print using system dialog, and set paper size to half sheet. Problem is that it automatically sets regular margins, and there is no way to change those from my printer dialog. End result - only half of the page prints, but it takes over a half because of the margins, so it would not fit on a label.

  • Print to PDF and then use Nitro PDF reader to send to a printer. When prompted, change paper size to half sheet. End result - it prints whole page shrinked to half sheet, and transposed.



EDIT: shipping label looks like this (personal information blacked out):



enter image description here

hardware failure - Keyboard suddenly starts to randomly skip letters


I have an Asus (K52Jr) laptop for almost 4 years now. I'm working from home for almost 3 years so I use the laptop extensively.


I never had a problem with the keyboard, but, suddenly yesterday it started skipping random letters. It seems improbable for me to be because of dust or something like that because it wasn't a process in which letter by letter the keys stopped working, instead it affects all the keys all of the sudden. For about 2 hours last night it worked well again, but this morning started acting strange again.


So, today I removed my keyboard and cleaned it thoroughly. It didn't help. It still skips letters. And I noticed something else today, also. If I keep a key pressed from time to time, while repeating the key, it stops a little, like I would lift my finger up and push the key again.


I can't understand what's going on. Could it be something with the data cable? When I cleaned the keyboard today I plugged out the data cable also (in case something wasn't plugged in correctly).


I also booted in Safe Mode, to see if it's a software problem, but the same issue occurred in safe mode also (even in the "Repair mode with command prompt")


Answer



I found out the problem. It wasn't the keyboard at all.


The battery I was using on my laptop started failing slowly a few months back, and it seems yesterday it was its last day (because Windows stared telling me that there is no battery detected even if the battery was plugged in).


I unplugged the battery and everything works fine now. Strange? Yeah. But it works :)


Monday, June 19, 2017

laptop - Selecting proper wattage in Universal power adapter

My AC adapter died and I went to BestBuy to purchase a replacement. The Geeksquad suggested to choose a lower watt capacity instead of a higher watt capacity. I was convinced of the opposite and anyway, my Dell XRS13 adapter was 45w producing 19.5v at 2.31 A.
The new Universal AC adapter is 65w producing (among various ranges) 19.5v at 3.33A. I simplistically figure that drawing 19.5 volts with higher amperage may heat-up the system or the laptop will only draw what it needs?
A 90 watt adapter would have produced the same voltage at 4.6A
Any chance it might damage my laptop by using higher amperage?
I noticed a previous post:



  1. A power supply doesn't "push" power. It provides. Just because it can provide more, doesn't mean the connected devices actually uses it. It's simple, really: I = U / R. The only thing that does matter is the output voltage. – Daniel B Mar 14 '14 at 12:03

power supply - Does a laptop computer charge faster when off?



A laptop power supply can supply a limited amount of power. Conceivably, then, when the computer is running, some of the power must be diverted to the processor and other components, leaving less to charge the battery. (Power usage is roughly 10 to 30 watts, or maybe more if you have a graphics card. In my case, my charger is rated for 65 watts.) Why doesn't my laptop battery charge while the laptop is in use? is an example of an extreme case. So it's plausible that this would affect charging speed.




So do laptops in fact charge significantly faster when turned off or asleep (while plugged into a sufficient power supply)?


Answer



It depends on the power supply. We have a few computers which can be run off a lower-wattage power supply while running - it will not charge the battery at all. If you attach a larger power supply, then it can charge and run.



Check with your laptop manufacturer. It seems somewhat common to see power supplies with different wattage being offered. The power supply with a higher wattage may be what you need to charge quickly and power the system while on. Check to see if a larger power supply is available if you need to charge quickly while using the system.


Kali Linux stuck on boot with a fast flashing cursor

When I Started my kali Linux, it got stuck with a fast flashing cursor. I disabled quiet boot mode and here's what I got,


(The cursor blinks pretty fast for a few seconds and then with normal speed)
enter image description here
On previous boot , I remember installing Vega!!!


It's Kali rolling 2017.1 dist-upgraded from 2016.1


Also I cant get into any terminal mode through Alt-F* for a few minutes(the screen switches back and forth between consoles). I can boot into recovery mode!


It's a Lenovo Z570 laptop dual booted with kali and windows 10. I installed bumblebee for my optimus card and so far worked fine!


Thanks in Advance!!


P.S: I Deleted and reinstalled Kali. so I'm not looking for answers anymore. but I'm leaving this question open in hopes of being helpful to someone if answered.

Fedora Dual Monitor - One Workspace Per Monitor



I recently upgraded to Fedora 11 and plugged in a second monitor for my at-home workstation. However, I'd really like to figure out a way to use each monitor as its own workspace that I can move back and forth between with my mouse.



Right now, a single workspace covers both monitors so when I open an application, it opens it on the left monitor only, regardless of which monitor the link to the application is on. Except for the Terminal link, oddly enough.



Any help would be appreciated.


Answer




I had a similar (not identical) problem to yours and managed to find a solution. Maybe it will be helpful to someone anyway.




  • I assume that you've got the two monitors working and that the single desktop is extended across both (i.e. such that you can drag apps onto the second monitor).


  • Right clicking on the GNOME panel at the top or bottom of the screen gives the option of 'New Panel'. Click this and drag the new panel onto the second monitor.


  • Now right click on the new panel and select 'Add to panel'. Scroll down to the bottom of the resulting list and select 'Window List'.




Now you have a list of windows on your second monitor. The new window list will only show the windows which are sitting on the extended part of the desktop, while the window list on your main monitor will similarly only show windows residing there.




All these windows are running in the same workspace, but this technique 'approximates' the one-workspace-per-monitor that you originally asked for. With this setup you can easily drag windows from one monitor to the other and, naturally, copying/pasting works properly too.


What is the cause of a high CPU usage of 'system and compressed memory' in Windows 10?




There is an observation to be made for Windows 10 on my laptop running with 24G memory available, and 2.5G used. There is no 'memory pressure'. Other questions have looked at memory consumption (which isn't the problem here). In all the related questions here and elsewhere, I havn't been able to find an adequate explanation to the issue of this exccessive cpu utilization over the last month or two after one of the Windows 10 updates.



I can accept that there is value in this service or process, but to run continually, and to use additional cpu resources, and as a consequence, use battery power less efficiently, that is the issue I am trying to resolve.



In some article on this site, it was suggested that I turn off SuperFetch, and set a registry entry for PrefetchParameters to 0. I did both and performed a reboot.



I reboot the machine, turn off screen saver, and start the task manager. After a few minutes, the service labeled as 'System and compressed memory' starts taking 5% of my cpu, consistently. My base cpu utilization is maybe 1%, which keeps the fan low. But when the 'system and compressed memory' service runs at the 5%, the fans ramp up. And just keeps running.



Sillyness. Why does that service need to be running consistently like that with no memory pressure? Any additional mechanisms I can try for turning it off or determining what it is actually doing? Are there logs file entries somewhere? Or an in-depth diagnostic tool?




how-to-disable-windows-10-memory-compression -- no real answers here



windows-10-system-process-taking-massive-amounts-of-ram



17993-windows-10-memory-compression



desktop-build-10525-and-windows-10-memory



www.techish.net/system-and-compressed-memory/




windows-10-build-1511-overheating-cpu-fan-always



Windows Performance Recorder - now need a link for info on how to interpret the info



scrub maintenance


Answer



Analyzing the ETL file with WPA shows, that the CPU usage doesn't come from system memory compression. It comes from ntoskrnl.exe!MiScrubMemoryWorker:



Line #, DPC/ISR, Process, Stack Tag, Stack, Count, TimeStamp (s), % Weight

8, , , , | | |- ntoskrnl.exe!MiScrubMemoryWorker, 79667, , 12,45
9, , , , | | | ntoskrnl.exe!MiScrubNode, 79667, , 12,45
10, , , , | | | ntoskrnl.exe!MiScrubNodeLargePages, 79667, , 12,45
11, , , , | | | ntoskrnl.exe!MiScrubNodeLargePageList, 79667, , 12,45
12, , , , | | | |- ntoskrnl.exe!MiScrubPage, 79663, , 12,45
13, , , , | | | | |- ntoskrnl.exe!RtlScrubMemory, 79653, , 12,45
14, , , , | | | | | |- ntoskrnl.exe!RtlpGenericRandomPatternWorker, 38549, , 6,02


This is a function to test the memory for errors by filling / reading some patterns (ntoskrnl.exe!RtlpGenericRandomPatternWorker).




This is by design and happens when the idle maintenance task kicks up when your device is idle.


security - Securely format a hard drive




I have just taken 8 old 250gb drives out of one of our servers.
I need to securely wipe all the data on these drives, before they are decomissioned.
Can anyone suggest an open source software that could do this? My idea is to mount the drive into a usb caddy, and run some kind of tool on the drive, to wipe it completely.

rename - Renaming all files of a particular type to lowercase batch


In this link Is there a way to batch rename files to lowercase?


there is a command given


for /f "Tokens=*" %%f in ('dir /l/b/a-d') do (rename "%%f" "%%f")

This works when i want to convert all filenames in a folder to lowercase.


However, is there any way to convert files of only one type (eg .RMT) to lowercase?


Thanks in advance.


Answer



Sure thing, just add "*.RMT" inside the dir expansion, so:


('dir /l/b/a-d')

becomes


('dir /l/b/a-d *.RMT')

Sunday, June 18, 2017

windows - Running python scripts in their directory with Notepad++


I am trying to get a run command set up in Notepad++ that will run the python file I have open in NP++ with the current_directory set to the folder containing the open script. It is not working, and I have hit a point where I can't figure out why.


I can get the run command to open CMD and change the directory appropriately with the following:


cmd /K cd "$(CURRENT_DIRECTORY)"

This works as I expect, CMD open in the current directory, waiting for a command. I can type python in here and python starts in this cmd window!


I expect the following run command to do what the previous one did, then run python in the CMD window:


cmd /K cd "$(CURRENT_DIRECTORY)" python

But this does not work, it gives the error:


The system cannot find the path specified.

Does anyone know why this would be happening / what I must do instead to get python to run here?


Answer



Does anyone know why this would be happening / what I must do instead?



cmd /K cd "$(CURRENT_DIRECTORY)" python



The above is an invalid command.


You should instead run the two commands sequentially using the & operator


cmd /K cd "$(CURRENT_DIRECTORY)" & python


commandA & commandB


Run commandA and then run commandB



Source Command Redirection, Pipes - Windows CMD - SS64.com


windows - Why does my computer run fast after a clean install?


I recently formatted and reinstalled Windows on my laptop. It now runs much faster.
I have been doing this about once a year for the past decade. Why is this needed?


I always figured this had to do with installing and removing programs, which over time fill up the registry with junk. Is this true? Are there any programs that can tweak the system without reformatting?


Answer



The registry is a bit of a misconception, The way it works, it could be filled with junk but it shouldn't slow down your machine - imagine, all roads are linked, but just because there is a traffic jam somewhere doesn't always mean it will affect you somewhere completely different!


It is pretty much just software that starts with your computer, updaters and bad drivers.


You can greatly speed up your computer using Microsoft / Sysinternals AutoRuns and delete/disable enries you do not want to start up with your machine.


windows 10 - Write to current user's registry through a different admin account


I have 2 users:



  • Domain\Me (domain user)


  • .\MeAdmin (local administrator)



I frequently have to update my registry for multiple purposes (IE trusted sites, override policies, etc.).


e.g.


[HKEY_CURRENT_USER\SOFTWARE\Policies\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\gov.pt]
[HKEY_CURRENT_USER\SOFTWARE\Policies\Microsoft\Windows\CurrentVersion\Internet Settings\ZoneMap\Domains\gov.pt\portaldasfinancas]
"https"=dword:00000001
"http"=dword:00000001

My problem lies with the fact that have been told that I cannot make myself (domain account) local admin, I have to use an independent local admin account for all administrator tweaks.


The thing is, if I run this as user .\MeAdmin, it will run current user of MeAdmin and not user Domain\Me; if I run as Domain\Me, I will bump into permissions wall.


Is there a way to assign Domain\Me permissions to edit registry without being Administrator, or update current user of that account through local admin?


Note: I've read about remote registry connections, but I was hoping to still run this as a script/shell for automation purposes.


Update:
When I run through domain user (all HKEY_CURRENT_USER entries):


enter image description here


Answer



To access another user's registry:



  1. You must use the full path – you need HKEY_USERS\ instead of HKEY_CURRENT_USER (which is only a symlink to the former), and likewise HKEY_USERS\_Classes instead of HKEY_CLASSES_ROOT. Use whoami /user to figure out your SID.


  2. The registry hive must be loaded (mounted) – each user's registry is stored in their own ntuser.dat file (HKCU) and UsrClass.dat (HKCR) separately from the system registry (loaded/unloaded on login/logout).


    In case the target user isn't logged in, you can use reg load or the similar Regedit menu item to mount their ntuser.dat under HKU (but don't forget to unload it later, or that user might be unable to log in).


  3. The registry keys (folders) must have the correct permissions allowing write by another user – they work more-or-less the same way as file permissions; open Regedit, right-click a folder, choose "Permissions…", and add the user which is doing the modifications.



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...