Friday, November 30, 2018

Dell OEM windows 7 disk

I have Dell XPS laptop, which is not booting at all.


I have Windows 7 activation code attached to bottom of my laptop. Would like to know if I buy Dell OEM Windows 7 disk to install Windows 7 and use my activation code to activate it, will that work ?


Thanks

sleep - Task scheduled to wake laptop - only works when lid is open

I am running Windows 7 Starter on an Acer Aspire One laptop.



I want my laptop to automatically run a task (backup the HDD to a network drive) once a week in the middle of the night. I scheduled the task in "Task Scheduler" and checked the box to wake the computer to run the task. I also changed the advanced power settings to allow wake timers. This was half of the solution. It now works flawlessly when the lid is open... the computer can wake itself up from either sleep or hibernate mode to perform the backup. When the lid is closed however, its sleeping beauty.



Any ideas? I don't want to have to remember to open the lid once a week. It sort of defeats the purpose of an "automatic" backup.



Update: I discovered that it can wake from sleep (or hybrid sleep), but not from hibernate when the lid is closed. This is good news. I'd still be curious about how to get it to work from hibernate, but I'm pretty happy about waking from sleep at least.

Thursday, November 29, 2018

powershell - Batch renaming of files by calculating a value and using it in the new name

I have a few hundred JPGs that need to be renamed. I need the following simple equation applied to the existing number in each file name:



(x-290)*-1




"Vitrine Hinge.0.jpg" would become "Vitrine Hinge.290.jpg", "Vitrine Hinge.1.jpg" would become "Vitrine Hinge.289.jpg", and so on.



Some of the files in question



I have used the following:



Dir *.jpg | `
foreach {
$data = $_.name.Split(".")
Rename-Item -NewName { '(' + $data1 + '-290)(-1)' }

}



And I receive errors.

How to restore the ability to modify the association for the .txt file extension in Windows 7 Pro?



The Problem:




  • The Properties dialogue box for text files has lost its accustomed Change button

  • From the list of extensions in Control Panel\Programs\Default Programs\Set Associations, the .txt file extension is missing

  • In the Open with dialogue box that can be accessed by right-clicking a text file, and then selecting Open with, and then Choose default program..., the option to Always use the selected program to open this kind of file is unchecked and grayed out

  • The .txt file extension is currently associated with Explorer, which, for the above reasons, I do not know how to change.




The Cause:



This all came about because I accidentally set the .txt file extension to open with Explorer. Clicking on a .txt file now causes Explorer to attempt to open it several times a second, until Explorer crashes, or I restart the system.



Subsequent failed attempts at solving the above mess include:




  • Trying to set a new file association for the .txt extension, using Assox1000


  • Trying to set the Open with dialog box option to Always use the selected program to open this kind of file as unchecked by default, by applying (unsuccessfully) the registry edit that apparently should accompany pasting MyOpenAs.dll into System 32

  • Using unassoc_1_4 to unassociate the .txt extension from everything

  • Using filetypesman-64 to delete the .txt extension altogether

  • Running sfc /scannow to fix missing Windows components

  • Using CCleaner to fix the registry

  • Applying a backup of an earlier registry condition



I'm feeling very tired and very foolish, right now, and would hugely appreciate any genius suggestions!


Answer




From here:



http://answers.microsoft.com/en-us/windows/forum/windows_7-files/windows-7-endless-explorerexe-chain-on-file-type/9b7d0c94-9ceb-4324-8fd0-4c29582154c6



I learned this:




Found it in the Registry. Only proceed if you are insanely frustrated
with this issue.




Look at the value in the following key in the registry.
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts.jar\UserChoice



Does it look something like Windows\explorer.exe? Not good.



Delete the following key in the registry.
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts.jar\UserChoice



Now, you can go to an Explorer window and choose a new default program
for .jar files.





I applied this advice to the .txt extension, and it worked.



Unfortunately, the New Text File option in the Explorer context menu was garbled. I managed to restore that from the following sage words (from http://articlebin.michaelmilette.com/new-text-document-context-menu-missing-after-associating-notepad-with-txt-files/):




you can re-create [a missing context menu item for New Text Document] by
copying and pasting the following as text file into Notepad or
Notepad++ and saving it as fix-new-text-document.reg. Last, double

click on the file to import it into the registry. Windows will likely
ask you to confirm that you really want to do it.



Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\.txt]
"PerceivedType"="text"
@="txtfile"
"Content Type"="text/plain"



Wednesday, November 28, 2018

keyboard shortcuts - How can I jump 2 words at a time throughout Windows?


Ever since I learned about using Ctrl with the arrow keys, backspace key, and delete key, I've felt my typing and editing productivity go up significantly.


I'd like to know if there's an easy way to define a shortcut to jump 2 words at a time, delete 2 words at a time, etc. that can be used natively throughout Windows like Ctrl + can?


If not, is it possible to implement via something like an AutoHotKey script? (eg. Ctrl + Alt + to jump 2 words to the left or Ctrl + Alt + Backspace to delete 2 words at a time?)


Answer



AutoHotkey will do exactly that. Or you can tailor the shortcut keys to be context specific and only trigger when certain programs are active.


#Persistent
#IfWinActive ; Every window. Change this line to tailor specificity
^!Left::SendInput, ^{Left 2}
^!Right::SendInput, ^{Right 2}
^!Backspace::SendInput, {Backspace 2} ; delete two characters at a time
^!Backspace::SendInput, +^{Left}{Backspace} ; delete a word at a time
^!Backspace::SendInput, +^{Left 2}{Backspace} ; delete two words at a time

Pick only one of the three definitions for Ctrl + Alt + Backspace obviously.


Hotkey modifiers are in the AutoHotkey help file, but for quick reference, ^ is Control, ! is Alt, + is Shift and # is the Windows button.


If you need to make a multi-line macro with sleep statements or something, start on the next line after the hotkey definition and end the macro with a Return statement.


^!Left::
SendInput, ^{Left 2}
Sleep 200 ; Sleeping 10 to 200ms can help for
; reliability in multi-key-press functions,
; depending on what you're doing
Return

blocking - How to block all but a specific list of IP addresses on a given port using IPSEC on Windows?

I have a list of IP addresses.


L={x.x.x.x,y.y.y.y,...etc}


I want to block all IP addresses except for the ones in the above list.


How to do using IPSEC commands in windows machine?


I tried to figure out from the following Microsoft link. But no luck :-(


@Ramhound


My Goal: Block all ips on 198.18.84.161:80 except for the IP 198.18.84.162


I tried the following.


1) To block all ips on port 80.


Steps:


netsh ipsec static add filterlist name=filterlist_198.18.84.161


netsh ipsec static add filter filterlist=filterlist_198.18.84.161 srcaddr=any dstaddr=Me
protocol=tcp srcport=0 dstport=80


netsh ipsec static add filteraction name=action_198.18.84.161 action=block


netsh ipsec static add policy name=policy_198.18.84.161 assign=yes


netsh ipsec static add rule name=rule_198.18.84.161 policy=policy_198.18.84.161
filterlist=filterlist_198.18.84.161 filteraction=action_198.18.84.161


Result: It blocked all ips on port 80


2) To Allow IP 198.18.84.162 on port 80 of the machine 198.18.84.161


Steps:


netsh ipsec static add filterlist name=filterlist_198.18.84.162


netsh ipsec static add filter filterlist=filterlist_198.18.84.162 srcaddr=198.18.84.162 dstaddr=Me
protocol=tcp srcport=0 dstport=80


netsh ipsec static add filteraction name=action_198.18.84.162 action=permit


netsh ipsec static add policy name=policy_198.18.84.162 assign=yes


netsh ipsec static add rule name=rule_198.18.84.162 policy=policy_198.18.84.162 filterlist=filterlist_198.18.84.162 filteraction=action_198.18.84.162


Result: This unblocked all IPs on port 80 instead of only unblocking 198.18.84.162

battery - My laptop charger blew a fuse in it, should I just short it?

Soo, I recently had a voltage surge at my house, and a couple of my chargers blew up. My laptop's charger was one of them. Upon opening I found out that only a fuse labelled T3.15A/ 250V had burned. Everything else looks fine. So my question is, can I just skip the open fuse and connect the two terminals of it with a piece of wire? I understand that the next time a voltage surge hits me and the MBC doesn't stop it, the charger will probably blow up, unless of course if I add a fuse externally to the charger. Like a do have an extension board which has a built-in fuse, so I guess that'd probably work.



And I know that this probably isn't worth it in the first place, but still I want to try it for the fun of it. I am planning to get a replacement charger anyways.



Also the replacement charger I'm planning to get has the same 3.34A & 19.5V rating, but is made for a different laptop (Insipiron 15 3521, mine is 15 3531) Will it do fine or will it cause damage to the battery?



Edit: Just to clarify, I wasn't trying to use this under normal working circumstances at all, I just wanted to know that would it be possible to just bypass the fuse given that the current will remain within safe limits or a additional fuse of same or lower rating is applied beforehand.

Tuesday, November 27, 2018

How to add Windows Media Center?


On Windows 8 Pro, I'm trying to add Windows Media Center using the Add features to Windows 8 dialog, but when I enter my product key I get the message This key won't work. Check it and try again, or try a different key.


Add features to Windows 8 error


I ditched my cable boxes for Cable cards, so I can't watch TV without Windows Media Center.


How can I install it? Do I need to buy a key for it?


Answer



After patiently waiting for the official launch of Windows 8 for my key to work, I was disappointed to see it didn't.


Fortunately though, until January 31st, 2013, Microsoft is offering the Windows 8 Media Center Pack for free.


If you don't have Windows 8 Pro, or miss the offer deadline, you would have to buy a key by choosing I want to buy a key online. The same website has a deal for the Windows 8 Pro Pack which includes, the Windows 8 Media Center Pack.


windows 10 - Microsoft reserved partition (Unable to detect file system!) + CRITICAL_PROCESS_DIED error

EDIT : I finally did this actually it is a little long story. I install windows 8 and i had same issues after one rebooting but after another reboot it can boot and i install bitdefender there is no problem now with windows but this time i couldnt open ElementaryOS :D:D i just solve this issue now just open command line and write : sudo apt-get dist-upgrade and it install something and DÄ°SABLE secure boot . So i just write this on my elementaryOS i hope it can be usefull for everyone :)


Befor windows start


it try to repair but cant do anything when i try to format i have same issue


Hello guys i just install windows 10 after this i just install Elementary OS as a second system. And today when i try to open windows i have CRITICAL_PROCESS_DIED error and when i open with elementart os and look gparted it says :


Name : Microsoft Reserved Partition
File System : Unknown
Size : 16.00 Mib
Flags: msftres
Status : Not mounted


Warning :
Unable to detect file system! Possible reasons are:
- The file system is damaged
- The file system is unknown to GParted
- There is no file system available (unformatted)
- The device entry /dev/sda3 is missing.


i search about it but i cant find any solution. Thanks for any help :)


Edit : i install Windows 10 and same day Elementary OS but after that i could use windows bootloader too. Ä° mean i could use both system. One night i was close computer and morning i cant open Windows


Progress is like this:
1. Push the Open button
2. When pc try to open i just have blue screen - Process died error-
3. Pc try to restart itself and i see a text "Try to repairing"
4. It said that it cant be repaired and pc close.
"Sure i will add a video or photos"

And that is 2. answer :


Model: ATA ST1000LM014-SSHD (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags:
Number Start End Size File system Name Flags
1 1049kB 473MB 472MB ntfs Basic data partition hidden, diag
2 473MB 578MB 105MB fat32 EFI system partition boot, esp
3 578MB 595MB 16.8MB Microsoft reserved partition msftres
4 595MB 822GB 821GB ntfs Basic data partition msftdata
5 822GB 983GB 161GB ext4
6 983GB 1000GB 17.1GB linux-swap(v1)

compact disc - How to avoid unwritable CDs and DVDs?

TL;DR: Writeable optical discs have a relatively short shelf life prior to use (compared to the service life of the data you record on them). Why? And how can you avoid having a stockpile of unused discs that become unwritable?




Background


Half a dozen years ago, I stocked up on DVD-Rs and have been working my way through them without a problem. Then the other day, disc after disc failed during the writing or verification process; different brands, discs from unopened canisters, writing on different computers. I tried discs from a slightly newer batch and everything worked fine.


Data recorded on writable optical discs is often touted as having an archival life of many decades. I had incorrectly assumed that you could write on the discs at any time. It turns out that while degradation is a long, slow process, there is a limited window of opportunity to get the data on the disc. Fairly early in the disc life, the data layer materials lose the ability to record data.


There have been various studies of optical disc life and aggregations of manufacturer data. The published longevity figures typically look like these from the Optical Storage Technology Association:


Unrecorded CD-R: 5-10 years
Recorded CD-R: 50-200 years
Unrecorded DVD-R: 5-10 years [1]
Recorded DVD-R: 30-100 years


[1] OSTA doesn't list the estimated unrecorded DVD-R shelf life, but the Council on Library and Information Resources lists the same 5-10 years as for CD-Rs, so that is shown above.


Note that testing conducted by the National Institute of Standards and Technology and the Library of Congress estimate longevity at only a fraction of those numbers. The point here isn't the specific numbers, it's the relationship between the unrecorded shelf life and the data archival life.




The Question


Obviously, you can avoid having a lot of unwritable discs by just treating them like a perishable commodity--don't buy more than you can use before they go bad, and store them under ideal conditions. My basic question is can we do better than that? Two parts:



  1. What is the nature of the problem? For example:



    • Why do they become unwritable?

    • Is it part of the same degradation process that eventually makes them unreadable, or is it a separate phenomenon?

    • Is it a basic characteristic of all of the different dye layer materials or is it substantively different in certain materials?

    • How does the writability window relate to the archival life? For example, is the time period similar across the whole family of materials or a somewhat fixed portion of the service life?


    Keep in mind that this isn't a graduate course in chemistry or material science. An in-scope answer to this part will be a few paragraphs at a level intended for curious computer enthusiasts.


  2. Does the nature of the problem provide a solution? For example:



    • Is there material-specific information that can be used to better plan around the expected writability limit?

    • Is there a way to store the unused discs that has been proven to prolong the writability window?

    • Can we identify discs ahead of time that will have a longer unused shelf life? For example, by identifying the material, or if the writable period is proportional to the archival life, buying "long life" discs would give the longest writable period.

    • If there are known factors that correlate with the writability period, are they readily identifiable, such as through visual clues or product terminology?



Note that the bullets under the two question parts are not meant as supplemental questions, which would make this overly broad. Rather, they are suggestions for the kinds of topics in answers that would address the question; i.e., they are there to provide context and focus on the intent of the question. On part 2, there may not be any solution; the bullets are intended to trigger thinking on different angles that might be useful so a potential solution isn't overlooked.

windows - How to prevent opening same program on terminal server by the "same user" with command prompt?



I have several users that use Remote Desktop App (Server 2008) and when they open the .BAT file I have created, it opens up two programs...however, I need to prevent the same program (in this case Outlook) from opening up multiple times...



I created this line in my .BAT file...




tasklist /nh /fi "imagename eq outlook.exe" | find /i "Outlook.exe" > nul ||(start /min Outlook.exe)


It works fine...except, I have multiple users logging on to this "terminal server" and running the same .BAT file...so what happens is when "User 2" logs on, they don't get Outlook started because it already shows as running in the task mananger under "USER 1"...



I need to be able to distinguish the "imagename" and "username"...well the "username" would be %USERPROFILE%


Answer




How to prevent opening same program on terminal server by the “same user” with command prompt?




I have multiple users logging on to this "terminal server" and running
the same .BAT file...so what happens is when "User 2" logs on, they
don't get Outlook started because it already shows as running in the
task manager under "USER 1"




Give the below logic a shot as it'll use the %Username% environmental variable to only get the current TASKLIST entry for the Username of the user account profile that runs that command. . .



TASKLIST COMMANDS TO GET PROCESS FOR ONLY THE USER RUNNING IT




TASKLIST /NH /FI "USERNAME eq %Username%" /FI "imagename eq outlook.exe"


USING WITH YOUR EXAMPLE LOGIC



TASKLIST /NH /FI "USERNAME eq %Username%" /FI "imagename eq outlook.exe" | find /i "Outlook.exe" > nul ||(start /min Outlook.exe)






Additional Reading and Resources




partitioning - linux can't read partition table


My laptop has a Hitachi HTS725050A7E, this is 500GB with 4k block size. It shipped with two partitions, a 10G recovery partition on the front of the disk and the remainder of disk space in one big primary partition for C:. I used the Win7 disk manager to shrink the main partition to 358G and booted the newest linux mint livecd.


This is where it gets weird: In the linux mint installer, when I went to create my partition, the two existing NTFS partitions are not detected.


I quit the installer and in the terminal tried sudo fdisk -l and it also does not find the NTFS partitions, instead it says the entire disk is one huge FAT partition. Bless linux mint for having TestDisk in it's repositories, i was able to quickly install that and search for the partitions. TestDisk could find them by searching but also saw the huge FAT partition. I booted back to windows and ran TestDisk there, and got completely different results. In Windows, TestDisk didn't even see any FAT partition and was able to correctly read the two NTFS partitions from the partition table without searching.


I tried an ubuntu live CD with the same results and I also examined the harddrive in all three OS using DFSee and had similar results. DFSee in windows could understand the partition table and in linux it could not. I think there must be some kind of error in the partition table that windows is covering up, or maybe the windows driver for the disk is interacting with the disk firmware in a different way than the linux driver.


So here is my question: I have two options here using TestDisk and I'm not sure which is best... I can create a backup of the partition table in TestDisk windows, boot to a linux live CD and restore the partition table from the backup. Or, in a linux live cd, use testdisk to search for partitions and try to restore the partition table that way.


Which is best, or is there a different direction I should go in? I need to have linux installed on this laptop.


update: the partition table is in MBR format.


update: I've uploaded the log file from testdisk (windows) here: http://is.gd/orM5O7. You'll see in the first part after it says Analyse Disk /dev/sda then it comes up with the correct partitions. But when it starts searching it sees a FAT partition at 0/1/1.


I've also uploaded the testdisk log from linux: http://is.gd/mLay6f. In this log you can see that when it starts it doesn't have the correct partitions right off, but after searching it can find them.


Finally, attached here: https://docs.google.com/open?id=0BzuZ-DbTYjC2R01nbEdrdW02NDQ is the first 512 bytes of my disk (I generated with dd if=/dev/sda of=sda.img bs=512 count=1). Looking at this in a hex editor, a missing piece of the puzzle is revealed. This first disk sector has the ASCII string DENALI_DATAPLEX near the front, and a little further down it has the string Dataplex ERROR: Mem alloc failed...Write error


Answer



Dataplex user guideTurns out these are all sideaffects of the NVELO Dataplex cache drive installation in the laptop. When Dataplex was installed it did this munge to the partition table and fixes it with invisible driver magic in windows. We have to uninstall dataplex to use the drive from a non-dataplex aware operating system. They do not have linux drivers nor do they support any dual boot configurations, so the caching simply will not work.


http://nvelo.com/dataplex-download/ocz/SystemRequirements.php


linux - burning iso images to DVD ROM

Is creating .iso image before burning to DVD-ROM necessary? I mean, I never noticed this on windows before burning my files to DVD-ROM, I never created an iso image file. But I had shifted to linux, and on the course of learning some terminal commands, I saw it being mentioned After creating an iso file, we would burn it to disk., So, my curiosity is summarized as:


1) Is creating .iso image files before burning necessary?
2) If yes, why is it that is it needed?

power supply - Computer turns on when something else is turned on in the room


I have a desktop PC plugged into a wall power socket that wakes up from sleep when some other device is turned on plugged into a power socket in the room (different socket other side of room, but most likely power running from the one wall socket to the other). Seems to depend somewhat on the load of the device turning on. e.g. plug a heater in and turn it on and the computer will wake from sleep.


Is their a bios setting or something else I can do to stop the computer waking from sleep in this fashion?


UPDATE:
Ok spent the last 30 min trying all sorts of different combinations to rule things out. Computer only wakes up when keyboard and mouse are plugged into the USB hub. Hub itself with nothing plugged in doesn't have an issue, only when keyboard + mouse plugged in.


So somehow fluctuations in power in the room result in the keyboard/mouse waking the keyboard up when going through the hub. Very odd. Anyone know why?


Answer



Best guess would be that all the outlets are on the same circuit so a power drop on one outlet creates a power drop on all outlets. Your computer is most likely plugged into a surge protector, not a UPS. It is running in sleep mode so the processor is spun almost off, main power to all devices except for USB is mostly off. Video, HDD... all spun down. The USB power is kept for "Wake on USB". Assumes USB keyboard and/or mouse. Wake would bring system out of sleep when it detects keyboard input or mouse shake.


During the power blip, the USB 5 volt drops a bit since the power supply is mostly shut off. Result is when the power comes back the USB sees almost like an input signal and wakes your computer.


Could try: powered USB hub (maybe it won't be so sensitive to the power drop?) or UPS on computer.


How do I use a custom keyboard layout created with Microsoft Keyboard Layout Creator in Windows 8?


Microsoft Keyboard Layout Creator (MSKLC) (v1.4) is not officially compatible with Windows 8. Some report that it works anyway but I cannot confirm that and there are other reports on the net that have the same problem. Because there seem to be several similar scenarios, let me be specific about the one I'm talking about here:


I'm on a Windows 8.1 machine (64 bit) and I have a custom keyboard layout created with MSKLC on my Windows 7 machine. When running the setup.exe on the Win8 machine, the keyboard layout seemed to install smoothly, just like on Win7.


The next step is to add the custom layout to whichever input language you want to use it with. That also works fine (although there is a foreboding because the preview doesn't work, it's greyed out). But the real problem comes after this: you wont find your new layout in the language bar and you wont be able to select it with the default keyboard shortcut Alt+⇧ Shift.


So the question is: is there a way to use the custom layout anyway?


Answer



Yes, there is a way to use the MSKLC custom layout in Windows 8.1. It's not more than a workaround, I'd say, but it works:


Go to Control PanelLanguageAdvanced Settings


Under Switching input methods select Options and then Advanced Key Settings


Here you can assign a shortcut that directly activates your custom keyboard layout (in combination with a language, so if you want to use the same layout with different languages, you need one shortcut for each combination in order to swap between these).


BTW: I suspect that the reason, why some people report that MSKLC works with Windows 8 is that they have only one keyboard layout or one language installed so that the system automatically uses the custom layout and hence there is no need for all of the above.


Laptop making clicking sound -- is it really hard drive failure?


Okay so I have had my laptop for I believe more than a year now and my laptop has always had this clicking sound every now and then. It's very random though -- sometimes I'll get it but then it won't do it for months. I looked it up and saw it was a hard drive failure so I immediately backed up my files just in case but so far my laptop hasn't died yet or had any super bad symptoms...


I have looked up a lot of things about it and I have run the software diagnostics to check to see if my hard drive is faulty but they all check out okay (the software I used was from the DELL site and I believe I went to my BIOS and did a check up through that as well) so I'm confused if this is really hard drive failure or if there could be some other reason? I do think something is wrong though because when it does make the clicking noise, some functionality on my computer does not work such as the windows button... But if its not a big deal I don't want to waste my money buy a new one. Ideally this laptop should last me another 3 years hopefully.


I have a DELL Inspiron N5110 if it helps. Any advice would be most appreciative.


Answer



It could be signs of the hard disk failing, or it could be something else - like aggressive power management parking the heads.


grep match till the first occurence of a character



I am tying to grep from the below







I am trying:



$ echo ''| grep -o "]>"



I am getting the above. So how to get only



Answer



echo ''| grep -o "]*>"


Your .* is greedy, it matched the first > and beyond. My [^>]* is also greedy, but it cannot match anything that includes >, so > in the pattern matches the first occurrence of > in the input for sure.


Monday, November 26, 2018

Windows 8.1 apps can't access my internet


I have Windows 8.1 Pro. I have been using it for 2 years but I never noticed that Windows apps don't have access to the internet connection anymore. I can use internet for surfing, downloading and other stuff but native apps like Store, Windows Update e.t.c. don't work. It worked fine when it was newly installed. I must have messed up with something. I have attached some screenshots:


enter image description here


enter image description here


You can see Store, Windows Update etc don't have access to the internet. My Windows is genuine and is activated.


Basically, I want to upgrade to Windows 10 and it requires updates installed. I can't install the updates because of this issue. The updates remain stuck at 0.


Answer



With regards to the the update problem. I also experienced it, I followed this answer, from this question and I solved my problem:



I've found that sometimes you just have to wait, but if it takes a
significantly long time try the following:



  • Click the start button and type in services.msc

  • Stop the Windows Update Service.

  • Delete the contents of the C:\Windows\SoftwareDistribution folder

  • Start the Windows Update Service.

  • Try Windows Update again.



Source


Windows update doesn't progress beyond 0 KB 0%


Windows XP Taskbar Grouping


It would be really nice if I were able to group applications in the xp taskbar according to the project I was working on...


For instance if i had two folder windows open, an im window, and a word doc... it would be nice to be able to group those in the taskbar and then right click on the group to minimize all of them. Then when I was ready to come back to them i could right click on the group and choose restore and it would restore those windows from their minimized state...


Anyone ever hear of this functionality? Or should I use a multiple desktop tool?


Thanks


Answer



If you end up going to the multiple desktops route, I recommend VirtuaWin. It's surprisingly light on system resources and you can move windows to different desktops and zoom around desktops with hotkeys (or use the tray menu for either). It doesn't offer any live view candy or anything like that, but it might just work for what you want.


ubuntu - Remote backups via sneakernet


I have a NAS drive with two internal HDs set up in RAID 0 (seen as one complete drive) and two separate external HDs as backups. I plan to keep the backups off site.


This means intermittently I want to copy the new data from the NAS to a third portable HD to the site of my backups and copy the new data over.


Without simply lumping all new stuff into a separate folder new and then sorting it manually twice (for the NAS and backups) is there a way I can create an image(?) of the backups to compare the NAS contents against and thus only copy the missing (new) files to the third portable HD using the 'sorted' file structure?


On-line remote backup is not an option.


Answer



Your best option in terms of performance would be to use rsync from the command shell on your NAS to sync NAS HDD to one of your external drives. In other words, you would plug your internal drive, then rsync NAS HDD onto that drive and take latter offsite.


Alternatively, you can do the same from any machine that has an access to NAS, but when a file will be copied from NAS to ext. HDD, it will go through this machine. Not ideal in performance terms, but might be easier to set up if you aren't comfortable with NAS shell. For this option, the keywords you are looking for is folder backup or folder sync. Assuming you are on Windows, you can look at FreeFileSync (make sure to use older versions that aren't bundled with adware), Bvckup 2 or SyncBack SE. You can also use Windows own robocopy with /MIR flag if you want zero dependency on anything outside of bare OS.


Sunday, November 25, 2018

removal of suffixes from multiple files in windows - not duplicate


This may appear as a duplicate question but it is not. My problem is a little different. Actually, I had a folder with a lot of mp4 files and I wanted to suffix each of the file names with GOOD. Seeing answers to the previous question I did something and ended up actually suffixing with .mp4good. Thus a file originally a.mp4 became a.mp4good.mp4 instead of aGOOD.mp4 (what I actually wanted). Luckily, all these files are running but the names are not what I wanted. I request help how to get what I want from this point. I used rename command in DOS from the folder containing these files.


Answer



As you discovered, the syntax you used to append a suffix to the base name was incorrect. An explanation as to why can be found at How does the Windows RENAME command interpret wildcards?. That link also has the correct syntax to append to the base name:


ren *.mp4 ??????????????????GOOD.*

There must be enough ? to match the length of the longest base name.


Note that if you have some starting names of the form a.b.mp4, then the above will yield aGOOD.b.mp4. If you want a.bGOOD.mp4, then you need more than a simple REN command. You could use


for %F in (*.mp4) do @ren "%F" "%~nFGOOD.mp4"

If you put the command in a batch script then you must double the percents


@echo off
for %%F in (*.mp4) do ren "%%F" "%%~nFGOOD.mp4"

Currently you have names of the form a.mp4GOOD.mp4, and you want aGOOD.mp4.


The solution is:


ren *.mp4GOOD.mp4 ??????????????????GOOD.mp4

If some names have more than two dots, then again you will need more than a simple REN command.


for %A in (*.mp4GOOD.mp4) do @for %B in ("%~nA") do @ren "%B" "%~nBGOOD.mp4

Remember to double the percents if you put the command in a batch script.


Notepad++: is there a way to force it to keep the autoindented-whitespace type?

I wonder if we can force notepad++ to respect the previous whitespace character when it autoindents a new line:


list[CR][LF]
····item1[CR][LF]
····item2[CR][LF]
--->|

(notepadd++ screenshot recreation showing hidden characters, because I don't have enough reputation to post images, sorry xP)


If I am indenting with tabs I want a tab when notepad++ does an autoindent.


But if I am indenting with spaces, I do want spaces.

autohotkey - Mapping Ctrl+w to Alt+w sends both Ctrl+Alt+w


I'm using Autohotkey to map Ctrl+w to Alt+w for Cloud9 to close inner tabs with Ctrl+w like usual instead of their Alt+w. I tried to use the following simple mapping


^w::!w

But it sends Ctrl+Alt+w with closes all tabs except current tab which wasn't what I wanted.


How can I tell autohotkey to not actually send the Ctrl key that I press for this hotkey?


Answer



Try the following instead:


Ctrl & w::Send !w

AutoHotKey has special handling for remapping the Ctrl key to the Alt key:



When the source key is LCtrl and the destination key is an Alt key,
the line Send {Blind}{LAlt DownTemp} is replaced by Send {Blind}{LCtrl
Up}{LAlt DownTemp}. The same is true if the source is RCtrl, except
that {RCtrl up} is used.



This special handling is specifically designed to prevent the behavior you observed. If you think about a simpler remapping like p::v, you'd probably want CtrlP to be treated like ^v so that you can paste with your P. In general, AutoHotKey tries to allow modifying keys to do their thing while triggering a hotkey.


Excel won't format dates properly

I downloaded some data from my bank for some transactions.




Using MS Excel 2008 V 12.2 on a Imac 2015



I usually convert the dates to YYYY-MM-DD (System International Standard) so there is absolutely no confusion ever (as what 11-02-04 would mean), as with other formats, at any time in the future.



However, when I convert the data in the cell to YYYY-MM-DD using format, half the dates never convert. They remain 26/07/2015. The strange thing is there is no real consistency, some entries convert, some don't. It seems strange if an engineer would program their dates to different formats. I've tried everything, including manually deleting the entire contents of the cell, and replacing it with 2015-07-26, then it converts to July 7, 2015. I've researched this with no luck on the web, even looking at some answers in this forum. Would appreciate any help. I can try to post the sample excel here or a screen shot if possible.



26/04/2015  27/04/2015
29/04/2015 30/04/2015

2015-04-06 2015-05-06

14/06/2015 15/06/2015

26/07/2015 27/07/2015
26/07/2015 27/07/2015
26/07/2015 27/07/2015
28/07/2015 29/07/2015
28/07/2015 29/07/2015
2015-08-08 2015-10-08
2015-08-08 2015-10-08
2015-08-08 2015-10-08

20/08/2015 21/08/2015
20/08/2015 21/08/2015
23/08/2015 24/08/2015
23/08/2015 24/08/2015


Note that in August, only one date reformatted properly. Also in April.



Am not a techie, so would a appreciate simple step by step instructions on how to fix if you can help. Also a layman's terms to explain why this is happening would be great. it seems really mindboggling to me how/why/if an software engineer? would change date formats in mid month or whatever, and also why the date won't change properly even with complete deletion and manual input.




My other question, out of interest, is that I assume hundreds of brilliant engineers design Excel. And in decades of existence, how come the International SI standard of YYYY-MM-DD, the first format I would include on day one, is NOT even an option in the drop down field?



Thanks in advance for your kind assistance,



Stu

windows 7 - Why/how is svchost.exe using 6.5GB of memory?


What is going on here? I have almost nothing running.


6.5/8


By almost nothing, I mean Firefox, and some background network applications that are entirely passive and would never use this much memory.


Related services: UxSms, TrkWks, SysMain, PcaSvc, Netman, CscService, AudioEndpointBuilder, TabletInputService


The only thing I can think of is that I was running Virtualbox with Ubuntu for a little while but that is limited to 2GB of memory and it's no longer running.




Edit: I am most interested in the question of why/how? Likely a leak somewhere but given the services listed above, do any stand out as being a potential culprit?


Answer



svchost.exe is the process that runs all your Windows services. One of them has gone mad apparently. Right-click on svchost.exe and select "Go to Service(s)". That will tell you which service it is, and you can use Services Manager to restart or disable it if you don't need it.


For a better description with nice screenshots check out:




Per your update, you can check out a couple of those services:



  1. CscService: Related to the "offline folders" feature of Windows. Do you use that?

  2. UxSms: Related to Desktop Window Manager. Try disabling Aero, see if the problem occurs.


partitioning - Disk Management is not working properly



My Windows 7 computer's Disk Management is not working properly. I can shrink the D: drive which is not primary partition, the unallocated space comes out. I then tried to create a new simple volume.




After the wizard Disk Management says:




The Disk Management console is not up to date, please refresh.




I pressed the refresh button and the unallocated space remained the same amount. There is no new volume.



How can I shrink drive C: and extend it to drive D:? If I try to do this it will say:





The maximum number of partition has reached.




I think it may be because the C: drive is the primary boot drive.


Answer



If you have 4 partitions already then that's the limit.



Otherwise if you're still struggling try and use a 3rd party tool, such as GParted, while your current OS isn't running.




http://www.howtogeek.com/howto/windows-vista/using-gparted-to-resize-your-windows-vista-partition/


crash - DPC_WATCHDOG_VIOLATION on Windows 8.1 only when I Restart the PC




I am getting the dreaded DPC_WATCHDOG_VIOLATION on a newly setup Windows 8.1 rig. It uses a Gigabyte H87-HD3 Motherboard, i5 4570, 16GB RAM and has a Kingston 240GB SSD (no other h/w on the M/b). Logitech Wireless Keyboard K520 + mouse using unified USB receiver. The SSD is setup as SATA, AHCI is ON. UEFI is set to 'UEFI and Legacy'. I did not use the Intel drivers while setting up the SSD, I let Windows partition/format the Drive.



The System is stable otherwise but on almost all 'Restart' it freezes just after the Startup Screen comes up. Most of the times it crashes before password entry, occasionally it gets to password entry but freezes and crashes with DPC_WATCHDOG_VIOLATION soon after. If I power off and start, no issues.



Often I have seen that the network connection showing a yellow exclamation before crashing. I have tried updating the network drivers but no avail. (I am using on-board LAN no WIFI adapter in the system).



I have uploaded the Minidump files here. Any help with the crash analysis is greatly appreciated.


Answer



This issue was finally resolved by updating the BIOS and drivers via Gigabyte's App Center tool. I first updated the drivers, next, updated the BIOS (from version F5 to F6), rebooted and the BSOD stopped. Haven't got one in last 3 weeks, so I say we are good to go!


Saturday, November 24, 2018

windows 7 - Is it possible to offload winsxs to a usb flash drive?

My 277GB Laptop C:\ drive is being gobbled up by Windows7. Windows folder takes 80% of the disc (Treesize).
Running the OS from a USB stick is a bad idea (SE forums writer/s).
Only 15% of the disc is taken by the \User\ folders. Most of my data now lives on USB storage.
There is 2.64GB Free left on C:\ and thats after MS walked thru Windows Cleaner (useless in this situation) and some other small tweaks.
Moving winsxs would free up some 14GB. If that works, I would look for other folders to scuttle or better yet a way to move the OS.
Ideas?
Thanks

keyboard - Keboard keys not working properly

I have a Acer Aspire E1-431 ,



I installed windows 10 pro 32 bit



and i have installed big applications's(32 bit) like



  • Visual Studio 2015,


  • Sql 2012(Sequal server management studio)


  • Adobe



and other application as well..


Then my keyboard not working properly...



I need to press hard and some of keys are not working like (left shift
key, M key)..



How can i solve that?..Give me some suggestions. Thank you:)

linux - Android Studio Code not updating with install of new APK in system/priv-app

A little background:



  • Android Studio project compiled with a submodule

  • Module imported from .aar package

  • Working code, freshly cloned from Git. Main app operates as intended

  • Single line addition to the module


    Log.d("DemoModeManager", "stuff is happening here");


  • From the imported module, the decompiled .class file shows the new line of code as it should



Before the above addition is a second Log statement which appears in Logcat with expected values. Immediately after is the new line, which is never seen in Logcat (checking both in terminal and in android studio)


This is an extension of a larger problem in which ANY change/addition is not updated in the apk.


APK is installed as priveledged app in system/priv-app directory. Installation is the same as every other time I have had it working.


Install method (which has worked every other time)
rename and unzip apk file
adb root
adb remount
Delete all old files
adb push /app.debug.apk /system/priv-app
adb push /app.debug/lib/arm64-v8a/* /system/lib64/app.debug


This leads me to believe one of three things is happening:



  1. Software issue in which the APK is being overwritten somehow

  2. Hardware issue in which the APK never updates from an old version (despite being fully deleted from the device)

  3. Hardware problem which is unrelated to the APK


Some attempted fixes (in no particular order):



  • Rebuild project

  • Clean project

  • Refresh linked C++

  • Sync project with gradle files

  • Re-import gradle project

  • Sync with file system

  • Invalidate cache and restart

  • Wipe and reclone Git project

  • Uninstall and reinstall Android Studio

  • Disable instant run


Any thoughts or ideas to try would be much appreciated.

Friday, November 23, 2018

ubuntu 10.04 - Remove Windows boot loader

I recently changed from Windows 7 to Ubuntu 10.04 as my default OS.


I formatted the hard drive with Windows 7 on it, but it still shows the boot loader at startup.


How do I remove the Windows 7 bootloader?

External hard drive to work with Windows, OSX & Linux?


I have an 1 TB external hard drive and I'm going to use it with OSX, Windows XP/7 and Ubuntu, mostly for backup. I'm thinking of creating a bigger FAT32 partition to exchange files between the OS's and also create a GUID to boot up the Mac from the external HD.



  1. Does the Mac absolutely need a GUID to boot up from the external hard drive?

  2. Let's say I want to try a new Linux distribution, I put it on the external hard drive, does it have to be on GUID partition in order to show up and boot up on the Mac?

  3. What type of partition does Time Machine need in order to work? Also, will it work if the external hard drive has more than one partition?

  4. How do you recommend I partition the hard drive so that everyone can use it and I can boot up from it (OSX/Windows/Linux distros) and I can also use it for Time Machine?


Please don't recommend any 3rd party drivers, I've had my share of those, 1 TB is enough to partition so that's everyone's happy.


Answer




Does the Mac absolutely need a GUID to boot up from the external hard drive?



Yes. Apple has a support article on that.



Let's say I want to try a new Linux distribution, I put it on the external hard drive, does it have to be on GUID partition in order to show up and boot up on the Mac?



I would think so, yes. You might need rEFIt for that though. But even then, they say that "booting Windows or Linux from an external disk is not well-supported by Apple’s firmware. It may work for you, but if it does not work, there is nothing rEFIt can do about it."



What type of partition does Time Machine need in order to work? Also, will it work if the external hard drive has more than one partition?



It has to be an HFS+ Journaled partition. And yes, it works if you have multiple partitions. You can just choose which partition to back up to once you plug in the drive.



How do you recommend I partition the hard drive so that everyone can use it and I can boot up from it (OSX/Windows/Linux distros) and I can also use it for Time Machine?



You definitely need a GUID partition table and a HFS partition for the Time Machine backup. That leaves two choices for data partitions:



  • Linux has rather good NTFS drivers these days, so you could make your data partition NTFS. Unless you need to access it from your Mac. In that case you'd need the NTFS-3G third party driver, which works quite well for me though (install through Homebrew for example).


  • Windows and OS X fully support exFAT. Linux however doesn't, so you'd need a third party driver again.



Rerun failed Windows Update


One of my Windows 7 updates (Platform update for Windows 7 64bit) failed to install. It is an optional update but I want it to install anyway. I think since the update failed I have problems opening https websites in Chrome.


How can I rerun the installation of the update? I can't find a button or something else to do that. It is simply listed as failed in my Windows Update History.


If I download the update manually (KB2670838) and run it, it says the update is already installed.


Answer



Go to


Windows Update -> Update History -> Installed Updates

and deinstall the update. After that you can reinstall it manually.


macos - Retraining fingers with instant feedback (for a future without Esc key)

Preparing for the future and protecting my wrists, I've remapped some keys that I commonly type (eg for escape, I now press/release caps lock; for control, I hold caps lock with another key, for caps lock I press both shift keys).


But I'd like to have an alert, some instant feedback when my old fingers type the forbidden keys. So if I type ESC or CONTROL_L, I'd like nothing to happen and the screen to flash or beep or both. Flashing red would of course be delightful.


Going one step further, I also wouldn't mind trying out having an alert when I use the "wrong" SHIFT for capital letters and special chars, to see if that might help me break some old habits.


Is this possible?

Can I Replace SATA 3.0Gb/s hard disk with With SATA 6.0Gb/s in Toshiba Satellite c660 laptop?

I have a Toshiba Satellite laptop and by default there is SATA 3.0 fitted in it. Few days ago, it stopped working. So I need to replace it with a new one. The problem I'm currently facing is I don't know if the SATA 6Gb/s hard disk (in this case I'm planning to choose Seagate ST500LM000 SSHD Drive). Please tell me will this SATA 6Gb/s hybrid hard disk work with my Toshiba Satellite c660 laptop? Also, I don't know much about the dimensions of hard disks. So please tell me in brief.


Seagate Hybrid SSHD Drive:
http://www.seagate.com/internal-hard-drives/laptop-hard-drives/laptop-solid-state-hybrid-drive/


Dimensions: Length: 100.35mm, Width: 69.85mm Height: 7.0mm


Form Factor: 2.5"


The current hard disk's info:


Brand: Toshiba


Model: MK3265GSX


Data Sheet: https://storage.toshiba.eu/export/sites/toshiba-sdd/media/products/datasheets/mk3265gsx_datasheet.pdf


According to data sheet, it's dimensions are:


Dimensions: Height: 9.5, Width: 69,85, Depth: 100


Form Factor: 2.5" SIZE (7mm)


I'm planning to choose Seagate ST500LM000, Please tell me will it work or not?

Thursday, November 22, 2018

How to get Windows 10 Long Term Service Branch (LTSB)?



I am planning to transfer from Windows 7 to Windows 10 (maybe this is not a good idea). I heard that Windows 10 is not as stable as Windows 7, then the only choice is Windows 10 Long Term Service Branch (LTSB).



Where can I download the LTSB? Must I pay additional money for this version?



My Dell laptop has a Windows 10 Pro tag.


Answer



Windows 10 Enterprise LTSB is only intended for purpose-fit machines (e.g. POS terminals, ATMs, digital signage, medical devices, etc.) and should not be used on consumer machines. Consequently, it is not available through traditional retail channels. If you're looking to upgrade, Windows 10 Home or Pro is likely what you're looking for.




However, a 90 day free trial for LTSB is available for download on TechNet. You'll need to log in with a Microsoft account and register specifically for evaluation. Use beyond the trial period will require a volume license agreement with Microsoft.


Windows XP - Unmountable Boot Volume, No CD - wipe hard drive and reinstall Windows XP?

I have a computer running Windows XP SP3 that I recently changed some settings on. When I rebooted I received a keyboard error, so I pressed F1 to proceed and tried to boot into safe mode. Unfortunately, I received the dreaded BSOD with an UNMOUNTABLE_BOOT_VOLUME error (0x000000ed).


I do have a flash drive with an Ubuntu 12.04 .iso and I've already recovered my files. Now I want to wipe my hard drive and reinstall Windows XP, but I can't find a functioning Windows XP .iso file to boot from and do a fresh install. I also am not sure if I can find the service tag/product ID on my computer, which may cause problems later on.


Does anyone know of a way to totally obliterate everything on the hard drive (I tried DBAN but it didn't work for some reason - my hard drive is a bit funny) and reinstall Windows XP under these conditions? (I can't access anything through Windows, so I can't run win32.exe and I have to use an .iso.)

osx snow leopard - Which file system to use in between OSX and Linux


I have got my paws on a large USB drive which I'd like to use as a backup/general storage at the office. I was thinking of having two partitions one of Time Machine backup and one for general storage. As I will be using the disk for both my Linux workstation and MacBook Pro I was wondering what file system to use.


I have been reading up on old forum threads and questions here, and my understanding is that Time Machine demands a volume with HFS+ file system, meaning it would not work with ext4. Likewise HFS+ will be read on Linux, but performance-wise it would be questionable. The majority of the info I found is from 2009-2010 era, so I am wondering if there has been any changes, could someone confirm or deny these statements? or perhaps add more info on the matter...


Would it be then advisable to have one partition with HFS+ and one with ext4? I am skeptical if that would be much better... Furthermore, the disk utility tool in OSX doesn't give the option to format with Linux native, apparently it's more likely that one uses Win/OSX than Linux/OSX..


Answer



Linux can write to HFS+ without problems. If you really need read/write support from both OSes, then you only have one choice, namely to format as HFS+, since Time Machine won't work with others and macOS can't natively write to ext4 (see How can I mount an ext4 file system on OS X?)


Since Linux allows writing to journaled HFS+ volumes, use Disk Utility.app on your Mac to format the partition with HFS+ (journaled).


Newer macOS versions will by default use APFS instead of HFS+, but Linux support for APFS is still quite limited. There's a read-only FUSE driver, but in the future write support may be added.


hard drive - RAID-1 causes far more noise than non-RAID?

After moving two 2 WD 1TB Black drives to a hardware RAID-1 system on my GA-Z87X-UD3H Gigabyte motherboard they started making a lot of noise and rattle.


I've tested both of them separately in a non-RAID external USB/SATA case. They check out 100% fine and are extremely quiet, even under a heavy load.


After the move it sounds more like just "extremely heavy head movement". Not that the drives are physically mounted incorrectly. (The noise continues if I screw the drives in place, or use the mounting rails, or even just set the drives on a cardboard box near my computer. So I do not think it's a mounting problem.)


The RAID-1 menu says the drives are both fine and not in the middle of being rebuilt. The noise continues for days.


But when I move the drives back to their non-RAID external case, the drives are again extremely quiet. Even under extremely heavy read/write loads and testings.


Is there something in a RAID-1 that would instantly cause extreme head-movement noise? (Excluding the obvious "not physically mounted securely" and "RAID is currently being rebuilt" issues.)


I've disabled WindowsIndex and SuperFetch on all my Windows 7 systems. The only Windows software I have to monitor/configure the RAID is the Intel piece that comes on the motherboard CD. Don't see any "speed" or "acoustic" settings anywhere there either.


The WD Black 1TB is most likely one of the "modern drives". But I don't see anything in the motherboard BIOS or the RAID BIOS (ctrl-I) that mentions anything about "changing acoustic levels" or "run slower".


The only Windows software I have to monitor/configure the RAID is the Intel piece that comes on the motherboard CD. Don't see any "speed" or "acoustic" settings anywhere there either.


All I see on the WD site are: Crippled Acronis backup software. Simple diagnostics software (DOS or Windows). Formatting software for XP.


Nothing about "change options/settings for the drives or RAID controller".

kvm switch - Need a KVM setup to support HDMI and DisplayPort input with DVI or HDMI output

Here is what I want to connect via KVM to have one monitor and keyboard/mouse:



  • 1st Work laptop (HP EliteBook 8560P) with a DisplayPort and VGA video output - I bought a passive DisplayPort to HDMI converter

  • 2nd Work laptop (Dell) with an HDMI and VGA video output Personal laptop

  • Personal laptop (Sony vpvf2390x) with an HDMI and VGA video output

  • Personal desktop (nvidia card) with an HDMI and DVI and VGA video output


I want to connect these to an HP 23" LED monitor (HP2311x) that takes DVI, VGA, and HDMI video input and use my Logitech mouse/keyboard via their unified receiver.


I made an attempt at this using a SIIG 4x1 USB HDMI KVM Switch CE-KV0111-S1. This works great for everything except the HP laptop with the DisplayPort. With the DP to HDMI converter I can get the video to work going straight to the external monitor but not when it is routed through the KVM switch.


Are there any products that handle HDMI & DP input with HDMI or DVI output? Do I need a different DP to HDMI converter? Or should I convert everything to DVI for input? Or should I convert the HDMI's to DP and use a DP KVM switch?


Thanks




I talked to a tech at KanexPro.com and found out that there isn't such a product on the market. They have something similar Kanexpro DP KVM which would work if I had only DP inputs.


There isn't a way to convert HDMI to DP or DP to HDMI and run through a KVM Switch due to how HDMI works.


The tech's recommendation was to convert both to DVI which might work or get a USB switch and use the different inputs on the back of the monitor for my different computers (which would leave me switching the monitor and the USB switch).


Lastly he asked if I had VGA outputs on my computers which led to this idea: use the VGA outputs (left those off the question originally) if they support the native resolution of my monitor (1920x1080) and find a KVM which supports that resolution using VGA input and HDMI/DVI/VGA output.


Hope this helps someone else in the future.

firefox - How make java applets to run ALWAYS?

Every time I meet java applet on some site, I have a problems running it. Either I have outdated JRE or application is blocked message appears.


I want to make browser/JRE NEVER check java updates, because they are issued nearly every day. I am not developing nuclear missiles, so I need no so high security.


Also I need browser/JRE NEVER block applets, or permit me to run them by force.


How to put some option somewhere to do so?


UPDATE


Is there any principal difference between Java runtime and other runtimes like Flash? Why nobody has problems running flash applets like Youtube page while JRE applets always cause problems?

Wednesday, November 21, 2018

Insider Fast Ring fails to install since 15048, is there a log


Since 15048, I can't upgrade to the latest insider fast ring. No changes to hardware / software, but it's a rather limited system: 2GB ram, old HP system, running 32-bit OS. Not sure what type of CPU.


Is there an upgrade log that I can read to determine the cause of the failure?


Answer



The log files are located under C:\$Windows.~BT\Sources\panther.



The following log files are created when an upgrade fails, and the
installation rollback is initiated:


C:\$Windows.~BT\Sources\Rollback\setupact.log
C:\$Windows.~BT\Sources\Rollback\setupact.err



MS lists here all errors and possible fixes.


So open the C:\Windows\panther\setuperr.log to see what is failed and look in the list what the error means and how you can solve it.


Windows 10 Firewall - How to deny all outbound but allow only Windows updates?

Goals:





  • Use only Windows 10 Firewall

  • Block all outbound traffic by default

  • Allow Windows 10 updates

  • Limit which svchost services are allowed through



My progress so far on a fresh install:





  • Outbound traffic is denied by default

  • All default rules have been disabled

  • Core Networking - DHCP-Out: allowed

  • svchost TCP (remote ports: 80, 443) and svchost UDP (remote port: 53): allowed

  • The programs that I want connected to the internet are allowed



With my current configuration, Windows is able to update successfully, but all svchost services (almost 200) are able to connect to the internet. I want to reduce the number of svhost services that are allowed to the minimum.



On another attempt to reduce connected svchost services, I've created different rules for specific svchost services (while disabling the generic svchost rules stated above), but Windows updates do not work (my allowed programs work, though). The svchost services that I allowed in this attempt were:





  • Background Intelligent Transfer Service (BITS)

  • Client License Service (ClipSVC)

  • Security Center

  • Update Orchestrator Service

  • Windows License Manager Service

  • Windows Update Service




Do I need to allow svchost TCP (remote ports: 80, 443) and svchost UDP (remote port: 53) and then manually create new blocking rules for each of the other svchost services (basically inverting what I've tried)?



Thanks!

internet explorer - Why won't IE let users login to a website unless in In Private mode?


I'm not entirely sure this belongs on SuperUser.com. I also considered ServerFault.com and StackOverflow.com, but on balance, I think it should belong here?


We host a website which has the same code responding to multiple domain names. On 28th December (without any changes deployed to the website) a percentage of users suddenly could not login, and the blank login page was just rendered again even when the correct credentials were entered. The issue is still ongoing.


After remote controlling an affected user's PC, we've found the following:



  • The issue affects Internet Explorer 9.

  • The user can login from the same machine on Chrome.

  • The user can login from an In Private browser session using IE9.

  • The user can login if the website is added to the Trusted Sites security zone.

  • The user can NOT login from an IE session in safe mode (started with iexplore -extoff).

  • Only one hostname that the website responds to prevents login, the same user account on the other hostname works fine (note that this is identical code and database running server side), even though that site is not in trusted sites zone.


Series of HTTP requests in the failure case:



  1. GET request to protected page, returns a 302 FOUND response to login page.

  2. GET request to login page.

  3. POST to login page, containing credentials, returns redirect to protected page.

  4. GET request to protected page... for some reason auth fails and browser is redirected to login page, as in step 1.


Other information:



  • Operating system is Windows 7 Ultimate Edition.

  • AV system is AVG Internet Security 2012.


I can think of lots of things that could be going wrong, but in every case, one of the findings above is incompatible with the theory.


Any ideas what is causing login to fail?


Update 06-Jan-2012


Enhanced logging has shown that the .ASPXAUTH cookie is being set in step 3. Its expiry date is 28 days in the future, its path is /, the domain is mysite.com, and its value is an encrypted forms ticket, as expected.


However, the cookie is not being received by the web server during step 4. Other cookies are being presented to the server during step 4, it's just this one that is missing.


I've seen that cookies are usually set with a domain starting with a period, but mine isn't. Should it be .mysite.com instead of mysite.com? However, if this was wrong, it would presumably affect all users?


Answer



My analysis in my update regarding the cookie not being returned to the server was incorrect. At some point before my logging code ran, the cookie was being expunged from the cookie collection server-side.


Using Wireshark, I determined that actually, two copies of the .ASPXAUTH cookie were being sent to the server, one was invalid and one valid. Technically, the order of cookies is non-deterministic, so I think it was affecting people whose browsers were sending an invalid cookie first... ASP.NET just didn't consider the second, valid cookie at all.


As mentioned above, the cookie in question was .ASPXAUTH which is the default name for .NET's authentication cookie. We believe two copies of it existed as it had perhaps been sent under a different domain in the past (once as www.mysite.com and at a different time as .mysite.com).


The easiest solution, which worked perfectly, was to change the name of the authentication cookie, by setting the following in Web.config:






Then, just make sure that the new cookie is only ever sent with a single value which will match a given request!


MS Security Essentials does not update automatically


I've installed Microsoft Security Essentials and my Windows XP Professional SP3 and it does not seem to install update signatures multiple times a day as I'm used to from other virus scanning tools. The signatures were two days old when I updated it manually.


My user account is a limited one, running surun if that might matter. But if I double click the MSSE tray icon and click the Update button myself, it updates, so I guess it can't be a permission problem.


Answer



I've been using MSE for a while now, and it does not update multiple times a day.
It does update every few days though.


If your computer is set to automatically install recommended updates, then the updates will come even through Windows Update. (Make sure to have Microsoft update enabled).


Tuesday, November 20, 2018

Writing Numeric Values from Excel Cells to Text File without Scientific Notation in VBA

I'm having some trouble with a VBA module in Excel. I have a script that references cells in my spreadsheet and writes the values in comma separated lines to a text file.



The way I do it boils down to:




Dim line_data(0 to 1) As String
line_data(0) = SheetNameVar.Cells(7, "C").Value
line_data(1) = SheetNameVar.Cells(8, "C").Value

Dim line As String
line = Join(line_data, ",")

TextStreamNameVar.WriteLine line



Everything works as expected, but I keep getting values written to my text file in scientific notation if they have zeroes after the decimal. For example,



3.77265350125136E-03,0.169769407556311


I have the sheet displayed as decimals with six digits after the decimal, but that doesn't seem to affect the sheet writing.



I can't seem to find any information talking about Excel VBA converting the value notation when writing to a text stream. Is there a way to prevent this? Ideally it wouldn't rely on the sheet formatting so I can display less precision there for readability. But I need the values to appear like this in my text file:



.00377265350125136,0.169769407556311



Thanks in advance for any help!

windows - Running "net" commands with /domain flag outside of the domain

As a part of my work I sometimes connect to a network with an AD environment/Domain, and receive domain user credentials. However, my machine is not a part of the domain. So when I try to query the domain (inside a runas /netonly) window, I get this:


C:\Windows\system32>net accounts /do
The request will be processed at a domain controller for domain WORKGROUP.
System error 1355 has occurred.
The specified domain either does not exist or could not be contacted.

However, if I run the same command from a computer inside that domain I get:


C:\Windows\system32>net accounts /do
Force user logoff how long after time expires?: Never
Minimum password age (days): 0
Maximum password age (days): 42
Minimum password length: 0
Length of password history maintained: None
Lockout threshold: Never
Lockout duration (minutes): 30
Lockout observation window (minutes): 30
Computer role: domain.local
The command completed successfully.

Again, this is inside a runas /netonly window titled "cmd/exe (running as domain.loca\username)".
The same happens for all similar commands such as "net user username /domain"


Is there any way to query these "net" commands from a computer outside the domain (whilst having a domain user of course)?


As additional note, some external tools (like the Windows Resource Kit or even PingCastle) work perfectly with runas / netonly.

Monday, November 19, 2018

partitioning - btrfs shrink partition

After shrinking a BTRFS file system using "btrfs filesystem resize /mnt -20g", this space doesn't show up as free for allocation in GParted. It doesn't seem like GParted can resize the btrfs partition on its own either. Rebooting doesn't help.


The various ways to check freespace on a btrfs volume https://btrfs.wiki.kernel.org/index.php/FAQ#Why_are_there_so_many_ways_to_check_the_amount_of_free_space.3F
do show that the total space has shrunk by 20 GB.


How can I reclaim this space to use for another new partition on the hard disk?

windows - How to change password on RAR archive w/o modifying arch. files attributes (modified/created)?


How do I change the password of an .RAR archive, without changing the date/time attributes of the files in the archive? Unfortunately you can't directly change the password of the archive with WinRAR, you have to extract the files, and then make a new archive with the new password. So the created/modified attributes of the files in the archive get changed. I know you can manually change the attributes of a file with available utilities - but there are hundreds of files in the archive, each with unique attributes, so it would take a very long time to "fix" each file before re-archiving it.


I'm using WinRAR 3.51, the last free version. Windows XP Pro SP3.




Update: I don't care if the output is a .RAR file or a ZIP file


IZArc4.1 will convert the RAR to a ZIP, and it keeps the dates. The problem is it compresses the file - there isn't a "store" option, and setting the default to store in the main configuration doesn't effect conversions. The RAR contains uncompressed files.


None of these other archiving programs will even do a conversion. A couple claim to, or try to, but the errors returned indicate a very lousy application. So far I've tried PeaZip, 7-Zip, FilZip, TugZip, SimplyZipSE, QuickZip, and WinShrink (from downloads.cnet.com).


WinRAR gives the error "skipping encryped archive" when I try the conversion. It asks for the password first, and I know it's right, as I opened the archive, and I can read/view all the files in it. It works on non-encrypted files.


Answer



I solved this problem by converting the RAR archive to a TAR archive with IZArc, and then converting the TAR archive to an RAR archive with WinRAR (Tools-Convert-Compression for options). This preserved the date/time attributes, got past the problem that WinRAR won't convert a password protected archive (even though I know the password.)


keyboard shortcuts - Setting Global Hotkeys for VLC on Windows


Is there a way for setting global hotkeys on VLC working on Windows XP?


I looked through the internet and found out that this feature has already been implemented. But I couldn't find exactly how to enable this feature.


Answer



Did you check General > Hotkeys in Preferences?


Also, restart VLC if the global hotkeys do not appear to work.


Add Windows boot entries after installing Ubuntu?

I have Windows 7 on its own bootable hard drive, Windows 8 on its own bootable hard drive and Ubuntu on its own bootable hard drive. I'm using the BIOS to manually select on which hard drive to boot. I would like to combine them all in one boot manager/Grub. I was thinking that Ubuntu would be best. Is there a way to manually add the Windows drives to Grub?

Sunday, November 18, 2018

command line - how to open file in window on set position using autohokey from cmd/batch?


I having a hard time to combine my scripts which work separately...


basicly I have a batch script with following in it:


START "" "mpc-hc64.exe" "video.avi"

this will open my video in mediaplayer. so far so good. then I had some reading on SO and SE about how to open window on set position via cmd/bat and found out in answers about AutoHotkey (documentation: here). so I downloaded a zip with executable and created a AHK script:


Run mpc-hc64.exe
WinWait, Media Player Classic Home Cinema
WinActivate
WinMove A,, 960, 0, A_ScreenWidth-960, A_ScreenHeight-29

this will open my mediaplayer at the right side of my screen if I run this cmd/bat:


AutoHotkeyU32.exe "script 1.ahk"

and now I would need to combine all above into one batch which if I run it thet it will open my video file in my mediaplayer and on the right side of my screen. can enyone help?


Answer



I found a way (on official discord AHK chanel):


#Persistent
mpc := "C:\T4\mpc-hc 1.7.16 x64\mpc-hc64.exe"
avi := "C:\T1\scripts\avi.avi"
Run, % """" mpc """ """ avi """", , , pid
WinWaitActive, % "ahk_pid " pid
WinGet, mpc_hwnd, ID, % "ahk_pid " pid
SetTimer, CheckWindowPosition, 100
CheckWindowPosition:
if(!WinExist("ahk_pid " pid)) {
ExitApp
}
WinGetPos, x, y, width, height, % "ahk_pid " pid
WinGet, hwnd, ID, % "ahk_pid " pid
if(DllCall("GetParent", "Ptr", hwnd, "UInt", 3) = 0 && DllCall("GetAncestor", "Ptr", hwnd, "UInt", 3) = mpc_hwnd) {
if(x != 960 || y != 0 || width != A_ScreenWidth - 960 || height != A_ScreenHeight - 29) {
WinMove, % "ahk_pid " pid, , 960, 0, % A_ScreenWidth - 960, % A_ScreenHeight - 29
}
}
return

How can I clone my Windows 7 hard drive to an SSD that previously had Windows 8 installed?


I recently bought a new SSD, and decided to create a fresh install of Windows 8 on it. I quickly decided that Windows 8 wasn't for me, so what I decided to do instead was simply clone my existing hard drive (with Windows 7 on it) to the SSD.


However I forgot about things like the MBR and whatnot. So when I try to boot from the SSD, it gives me an error, because it seems to think it's Windows 8, even though it's really a clone of my hard drive with Windows 7 now. I'm guessing this is because the MBR wasn't updated or something to that effect.


My question is, how do I fix it so I can go ahead and boot Windows 7 from my SSD? I don't mind if the solution involves cloning the original hard drive again, as all of that data is still there on the hard drive.


Answer



I was able to solve this problem by booting from the Windows 7 DVD, going to command prompt, and doing bootrec /rebuildbcd.


I followed these steps to solve the issue.


How do I save a link to a webpage as a shortcut in the Windows file manager?



I want to click an icon in Windows Explorer and have it open a specific web page with the default browser. How is this done?



I don't want to download the web page, I just want to access it via a shortcut in the file manager. My google searches haven't turned up anything.


Answer




  1. Right click on the folder.

  2. New Shortcut.

  3. Insert the URL in the dialog, Next.


  4. Put a meaningful name.



Double click the shortcut to test it.


Asus P8H67-V AHCI Driver issues when installing Windows

I'm trying to install Windows as a dual-boot on an Asus P8H67-V (Socket 1155) PC running Elementary OS (Debian). 
Here's my configuration:



  • Intel Core I5-2500K

  • Samsung 840 Pro SSD

    • This previously had Windows 7 x64 installed.

    • I've cleaned it; now I'm trying to install Windows on it from scratch.


  • Samsung 850 Evo SSD

    • This is where I have Elementary OS installed.


  • Multiple WD Red (≥ 2 TB)

  • 2 × Zotac GeForce GTX 660

  • BIOS set to AHCI for boot

    • I consider switching back to IDE in BIOS not to be an option.



I'm trying to install Windows by booting from the following devices:



  • External DVD/BR Drive using a verified Win7_x64 Disc
    (this has worked on other machines)

  • Samsung USB Stick (128 GB, 8 GB Partition for Win10_x64)


I get this error message:


Load Driver

A required CD/DVD drive device driver is missing. If you have a driver floppy disk, CD, DVD, or USB flash drive, please insert it now.


Note: If the Windows installation media is in the CD/DVD drive, you can safely remove it for this step


This message appeared for Windows 10 and Windows 7.


The installers boot like a charm, as does Elementary OS.


I have tried:



  • Using both a USB 3 port and a USB 2 port. No success over here.

  • Somehow I was able to boot both devices in IDE Mode –
    still it wouldn't let me install... Same message.


  • Assuming that it has something to do with AHCI instead of IDE in SATA Mode inside BIOS Configuration, I downloaded AHCI Drivers from Intel (chipset manufacturer) and ASUS (motherboard manufacturer) but none of them worked. The drivers were shown as applicable for the hardware (Windows 10 Setup), but I was still not able to continue the setup process.



Question:



  • Is there a possibility to determine which exact driver is missing? The error message is not what I would call conclusive as it does not really state more than "It's not working, I don't know why."


  • Is there something I missed? Any other drivers to try? Any preparation for the Samsung 840 needed I missed?


community faq - How do I determine which graphics card I'm using?


I recently read this answer on Gaming.SE, which made me realize that I actually have no idea how to tell which graphics card I have in my PC. Where can I find this information?


Answer




  1. Open the system Control Panel, by typing Win+Break or going to My Computer and clicking on System Properties.


    system properties


  2. Click on your Windows Experience Rating to go to Performance Information and Tools


    performance


  3. Click View and Print detailed system information


    detailed performance info


  4. Scroll down to the Graphics section. If you have the proper drivers installed for your card, it should say under "display adapter type" what kind of graphics card you have.


    graphics details



How does Windows track in-use Memory Locations?


My understanding of the (basic) definiton of a Memory Leak is a location in memory that has been reserved but the pointer to that memory within the application that reserved the memory has been deleted/lost.


My question is this: in order for Windows (or indeed any operating system) to be aware that memory is still reserved after the destruction of the pointer used to manage that memory inside an application, it must independently track what memory is in use. Where does it do this, and how?


Answer



You are correct - every operating system tracks memory use and allocation separately. This is one of it's vital functions. For many reasons it simply wouldn't make sense to pass complete control over memory to a userland process - security can be pointed out as one example: Your process could store sensitive information in memory, thus Operating system should manage which processes will be allowed to access it.


Generally all operating systems have a sub-system named Memory Management (or Memory Manager in Windows), which keeps track of virtual memory. Another part of the OS, Hardware Abstraction, then maps this virtual memory to physical devices. This, of course, prohibits direct interaction between any user process and physical memory.


Directly interacting with this part of operating system is partially available through public API - see Memory Management Functions for Windows. In Linux there are several ways to access memory, this page would be best way to get started with it.


Windows 10 keyboard layout menu is contradicting itself


I used to cycle between three keyboard settings:



  • QWERTY

  • French AZERTY

  • Belgian AZERTY


I removed French AZERTY from the list, but since then, whenever I boot Windows I get contradicting information.


The keyboard layout popup screen (Win + Space) and the language bar (in the taskbar) both me I have the two AZERTYs available, but the language settings window tells me that I have the Belgian AZERTY and QWERTY (which is what I want):


enter image description here


The only way I can solve this is to remove the QWERTY entry, and then add it again. This adds the QWERTY option but it still doesn't remove the French AZERTY option:


enter image description here


This seems to fix the popup screen and the language bar (well, partially), but when I reboot I have to do it all over again.


How do I get Windows 10 to actually give me the keyboard layouts that I've configured, instead of some presumably cached version?




To pre-empt a possible comment, I only have one language (and thus keyboard layout list), this isn't a confusion with using the wrong group:


enter image description here


Answer



The link posted in a comment on the question led me to an acceptable (though not ideal) solution.



Method 2 : Preloaded



  1. Use regedit to navigate to HKEY_USERS\.DEFAULT\Keyboard Layout\Preload.
    You will find there the list of keyboards that are preloaded at boot.

  2. Find the keyboard identifier among the list of
    Keyboard Identifiers

  3. Delete the key.



I had to perform this action for both HKEY_USERS\.DEFAULT and HKEY_CURRENT_USER.


After that, the two expected keyboard layouts (QWERTY/Belgian AZERTY) were being shown on startup.


There are a few side effects though:



  • The Belgian AZERTY language is set to NL instead of EN, which is not what I want.

  • I have not found a way to make the Belgian AZERTY the default instead of QWERTY.


But this at least solves the core issue at hand. If anyone finds a solution that doesn't have these side effects, I'll happily give them the answer tick.


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