Is it possible to disable disk cache for a mount point on Linux system?
I have a s3fs mount on multiple systems and i need to disable disk cache for it. how can i achieve this?
Saturday, 30 November 2019
amazon s3 - Linux - How to disable disk cache for a specific mount point?
windows 10 - Safe sharing home network, single user Microsoft account without Homegroup
I have a home office with a workstation, and I just added another workstation and a laptop. All use windows10 professional and I use the same Microsoft account to login on all machines. I'm trying to set up a shared folder on each machine to replace the Homegroup.
Network Error
Windows cannot access \\ws1\shared
You do not have permission to access \\ws1\shared.
Contact your network administrator to request access.
I can't get the sharing to work no matter what I allow on the share permissions or on the folder security.
Windows10 just removed homegroup, a feature I was just beginning to get some use out of.
I've set up a domain in the past, in an office setting. But I'd like to keep this simple and avoid using a domain controller.
I also want to avoid sharing on the "public network" as the laptop might be taken to other locations and other devices exist in my home.
Edit:
Just found out that sharing any folder outside of the user folder is working. No adjusting of permissions seems to work though for in the user folder
windows 7 - Remove a part of a list of names
I have some files and each files have distinct name but all of them have the same "-statement" at the end like this:
flower-statement.mp3
leave-statement.mp3
ball-statement.mp3
goal-statement.mp3
So I want to remove this: -statement
Is that possible?
Answer
Why can't you just do this with batch like so without any special programs? From what I tested, this will do exactly what you're looking for it to do which is parse out the -statement
part of the file name and then rename each without it leaving the other parts of the file. This will work for all .mp3
files in a specific folder just fine.
In my below example where I have the C:\Users\User\Desktop\Test\*.mp3
just put your folder name in that location. Save that to a text file and rename to batch.cmd
or something like that. Then just double-click to run it to perform the rename of the files in that folder parsing out the -statement
part of it.
You can also make this script implicit to run the directory which you copy it to and just using *.mp3
from there rather than the full path.
EXPLICIT SCRIPT (specify the directory where *.mp3 are located)
@ECHO ON
FOR %%A IN ("C:\Users\User\Desktop\Test\*.mp3") DO (
CALL :RenameFiles "%%~A" "%%~NXA"
)
GOTO EOF
:RenameFiles
SET fname=%~2
SET renname=%fname:-statement=%
REN "%~1" "%renname%"
GOTO EOF
IMPLICIT SCRIPT (copy to and then run from the directory where *.mp3 are located)
@ECHO ON
FOR %%A IN ("*.mp3") DO (
CALL :RenameFiles "%%~A" "%%~NXA"
)
GOTO EOF
:RenameFiles
SET fname=%~2
SET renname=%fname:-statement=%
REN "%~1" "%renname%"
GOTO EOF
ADD SOMETHING TO THE END OF A RENAMED FILE BEFORE THE FILE NAME EXTENSION
(change fpart
and mp3path
to match what you need those to be for your usage. The fpart
is what you need to add and the mp3path
is the folder where the MP3
files reside.)
NOTE: This still assumes the MP3 files have -statement
in the file name to be stripped out.
EXCPLICIT SCRIPT (with parse file name characters)
@ECHO ON
SET mp3path=C:\Users\User\Desktop\Test
SET fpart=_something
FOR /F %%A IN ('DIR /B "%mp3path%\*.mp3"') DO (
CALL :RenameFiles "%%~FPA" "%%~NA" "%%~XA"
)
GOTO EOF
:RenameFiles
SET fname=%~2
SET ext=%~3
SET renname=%fname:-statement=%
REN "%~1" "%renname%%fpart%%ext%"
GOTO EOF
EXCPLICIT SCRIPT (no parse just add file name characters)
@ECHO ON
SET mp3path=C:\Users\User\Desktop\Test
SET fpart=_something
FOR /F %%A IN ('DIR /B "%mp3path%\*.mp3"') DO (
CALL :RenameFiles "%%~FPA" "%%~NA" "%%~XA"
)
GOTO EOF
:RenameFiles
SET fname=%~2
SET ext=%~3
REN "%~1" "%fname%%fpart%%ext%"
GOTO EOF
I want my old speed dial page on google chrome
I know this has been posted alot around here. But this is about the new google update after I tried to install google chrome on a new laptop. Google Chrome Version 29.0.1547.76 m has ruined the speed dial look I once had. It now shows a search input box and a smaller set of speed dials below it. (see image please)
Is there a way to get back the nice clean speed dial page we all love?
Answer
You can try the following:
- enter
chrome://flags
in the address bar - goto
Enable Instant Extended API
- Set it to
Disabled
- Restart Chrome
This worked for me (until Google decides otherwise).
Edit: If you go directly to chrome://flags/#enable-instant-extended-api
you don't have to search :)
Power-related limitations of a USB Hard Drive Enclosure?
What are the power-related limitations of a USB-powered 2.5" hard drive enclosure? Some external hard drives require an extra power source, while my current one does not require one.
Is there a certain limitation (Disk speed/RPM, storage size (500 GB>), specific power consumption) for enclosures where the power source is via the USB?
services - Is it possible to correct my GeoIP location
Numerous services and advertising do GeoIP lookups. They get the country correct, but often the city is wrong. Are there places where I can go and correct this, letting people know the actual location of my IP address. I have a static IP, so it's not going to go to another user in a different location.
compression - What does the number after 7-zip's -m switch mean?
7-zip has a command line switch to set the compression method, -m
followed by a number, e.g.-m0=LZMA
.
What does the number (0
in the example) mean? Different numbers produce slightly different compression results and performance:
Parameters Wall User System
-m0=LZMA -mx=9 -ms=on -mmt=off 28.4 27.48 0.85
-m1=LZMA -mx=9 -ms=on -mmt=off 27.45 33.06 0.90
-m0=LZMA -mx=9 -ms=on -mmt=on 12.74 24.39 1.14
-m1=LZMA -mx=9 -ms=on -mmt=on 15.08 33.14 1.28
-m0=LZMA -mx=9 -ms=on -mmt=off 26.5 25.58 0.65
-m1=LZMA -mx=9 -ms=on -mmt=off 27.07 32.84 0.87
-m0=LZMA -mx=9 -ms=on -mmt=on 13.27 24.99 1.00
-m1=LZMA -mx=9 -ms=on -mmt=on 15.32 33.28 1.47
Is there a command to change path from current location to default directory, in Windows command prompt?
Is there a command to change the current directory to default directory? (I'm not asking about permanently changing the default directory, here!)
For example, if the current directory is "..\xyz" and my default command prompt directory is D:\Abc, is there a way to navigate directly to D:\Abc (without giving >cd D:\Abc)?
Answer
There's no option built into cd
to do this but you could certainly create a .cmd
script file that does it. For example, you could put this into a home.cmd
file somewhere on your search PATH
and go to D:\Abc
just by typing home
:
@ echo off
cd /D D:\Abc
google chrome - how to block advertisement popups in web browser
I use Mozilla Firefox and Google Chrome as web browsers. But when i open it, a lot of unwanted advertisement pop ups and other windows would be opened.To close each and every pop ups and windows is a ridiculous and time consuming job.It makes my system slow. I tried to block it by blocking pop ups , plug ins and java scripts. If i block these pop ups....in some necessary situations (internet banking,railway ticket booking...) it will give me a negative result.I have given some exceptions (bank website) in pop ups blocking.Still the problem exists. How can i overcome this?
readline - How do I reload .inputrc using a bash script?
This question explains how to reload .inputrc
using C-x C-r
. But how would one reload it using commands in a bash script?
Answer
Use the bind
command:
bind -f ~/.inputrc
See help bind
for more information:
-f filename Read key bindings from FILENAME.
data recovery - USB drive is empty in drive management
I've got a USB drive here, that somebody asked to try and fix. When inserting it, it shows up in explorer, but when I double click it I get a message saying "Please insert a disk into drive H:". So I went to disk management, to see if it was correctly formatted. It doesn't show up in the upper pane, and in the lower pane it tells me there is no medium in H:.
After this I used chkdsk: the path is invalid. Then I tried TestDisk, which is supposed to look at raw data, and this can't even find the disk.
So I'm assuming the drive is dead, even though its LED is burning. But I was wondering if there might be something else I could try?
This system is Windows 7 Ultimate 64bit by the way.
(I'm translating things from a Dutch install, so some names might be wrong)
Answer
I've had two defective flash drives exactly like this. It is defective.
There is a possibility you might have some luck with Linux. (I was able to read and write data primitively to one of my defective flash drives.)
On Linux:
- Before inserting the flash drive, in the terminal, run the command
cat /proc/partitions
. This will list the drives detected by the system. - Insert the flash drive. I'll let you be the judge of when the flash drive could be "ready to go", but waiting five seconds should suffice.
- Run the command
cat /proc/partitions
again. If something new showed up, that's a good sign, and Linux is recognizing the flash drive. Proceed below if this is the case. Otherwise, I'm sorry, that flash drive may be a goner. :(
Safe data recovery with Linux:
It looks like you want to salvage the data off of that flash drive. The command cat /proc/partitions
should have returned something that looks like this:
major minor #blocks name
8 0 250059096 sda
8 1 174558208 sda1
8 2 1 sda2
8 5 67108864 sda5
8 6 8388608 sda6
8 16 1953514492 sdb
8 17 1953512448 sdb1
8 32 1953514492 sdc
8 33 1953512448 sdc1
9 0 1953511288 md0
Remember the new name that appeared. For example purposes, I'm going to say that both sdc
and sdc1
appeared.
If there's a number at the end, that means a partition was detected. It's easier to get data off when a partition is visible.
This command will save the entire contents of the partition sdc1
into a file called fdd_backup.img
in the directory that the terminal is currently working in (probably the home directory, if you didn't cd
):
sudo dd if=/dev/sdc1 of=fdd_backup.img conv=noerror
The output should be blank. For how long? It depends on how large the partition is and it might also depend on how corrupted the partition is.
dd
will say how the data transferred, and when you return to the terminal, that's when execution has completed.
Okay, now you can copy off fdd_backup.img
. Unfortunately, this is where my knowledge stops. I don't know what to tell you to help you recover this image, but I hope that you could get here so that you have something at least.
Get rid of "smart quotes" in Outlook
I'm not sure what I did, but the quotes (single and double) in Outlook 2003 have gone from straight vertical quotes to angled quotes. I've looked through Outlook's options and the Autocorrect options, and I can't seem to find anything that would enable/disable this feature?
Answer
If I remember correctly, you can press Ctrl + Shift + ' to turn this feature on or off.
The shortcut is undocumented (it doesn't appear in Keyboard shortcuts), and I'd say it's pretty easy to enable by mistake...
Excel: how to permanently apply conditional formatting to the whole spreadsheet?
I have the following annoying problem with Excel 2010. I use Conditional formatting to apply bold formatting to each line of the spreadsheet that meets a condition expressed by a formula. In the "applies to", I write =$A$2:$Q$149, which is the current extent of my spreadsheet. But I want this range to grow with my spreadsheet, i.e., I want the formatting to permanently apply to the whole spreadsheet. Regularly, my "applies to" field is transformed into a complex range, that selects most lines of spreadsheet, but not all, like =$A$2:$Q$138;$A$140:$Q$147. Have you ever encountered such a problem? Is there a solution?
macos - Aquamacs: How to Remap Capslock to Meta Key, at Application Level?
In aquamacs, how can I remap the capslock key to meta? I can remap command to control using:
(setq mac-command-modifier 'ctrl)
Is there a similar way to remap the capslock?
EDIT: I know that I can remap keys in the system preferences, but I'd really like to confine the damage to aquamacs only. Just like mapping the command key to ctrl, but for capslock.
Answer
Aside from the "Modifier Keys" System Preferences section, I don't think an application can override the behaviour of the caps lock key..
I'm fairly sure the Caps Lock key event is not passed to applications, nor can they override the toggle effect.. Maybe you could do something whereby you monitor caps lock key state, and send alt when it changes.. but this is extremely convoluted, and slightly useless (it wouldn't work if you hold the key..)
Do you really need the caps lock key in other applications?
If so, perhaps you could write an AppleScript to toggle the Caps Lock key mapping? For example, in pseudo-code:
loop forever:
if frontmost application == "Aquaemacs":
keys.capslock = "Meta"
else:
keys.capslock = "Default
Shouldn't be difficult using AppleScript, the code from this Apple support thread should be a good start:
tell application "System Preferences"
activate
set current pane to pane "com.apple.preference.keyboard"
end tell
tell application "System Events"
tell application process "System Preferences"
get properties
click button "Modifier Keys..." of tab group 1 of window "Keyboard & Mouse"
tell sheet 1 of window "Keyboard & Mouse"
click pop up button 1
click menu item "No Action" of menu 1 of pop up button 1
delay 3
click button "OK"
end tell
end tell
end tell
How to recover a removed file under Linux?
By accident, I used rm
on a file I didn't want to delete. Is there a way that I can get it back under Linux?
Answer
The following are generic steps to recover text files.
First use wall command to tell user that system is going down in a single user mode:
# wall
System is going down to .... please save your work.Press CTRL+D to send message.
Next use init 1 command to take system to a single user mode:
# init 1
Using grep (traditional UNIX way) to recover files
Use following grep syntax:
grep -b 'search-text' /dev/partition > file.txt
OR
grep -a -B[size before] -A[size after] 'text' /dev/[your_partition] > file.txt
Where,
-i : Ignore case distinctions in both the PATTERN and the input files i.e. match both uppercase and lowercase character.
-a : Process a binary file as if it were text
-B Print number lines/size of leading context before matching lines.
-A: Print number lines/size of trailing context after matching lines.To recover text file starting with "nixCraft" word on /dev/sda1 you can try following command:
# grep -i -a -B10 -A100 'nixCraft' /dev/sda1 > file.txt
Next use vi to see file.txt.
This method is ONLY useful if deleted file is text file. If you are using ext2 file system, try out recover command.
Found at http://www.cyberciti.biz/tips/linuxunix-recover-deleted-files.html
Friday, 29 November 2019
motherboard - What kind of board does an XMC network card fit in?
I'm looking at 10GbE network cards, and most of what I find are XMC format, like the XPort3300 (just an example). I'm trying to understand how these cards fit on a board. I'm very new to low-level hardware, so it's very confusing for me.
Will these kinds of cards fit on a standard motherboard, like in a desktop PC? Do they require something specific?
If it helps, I'm more interested in Intel, rack-mounted systems.
usb hub - How many devices can be plugged into a USB hub, and how is power distributed amongst them?
Is it possible to connect a USB hub to a hub that is connected to a hub and a hub and.. and.. and to a laptop?
I was thinking there are bound to be some "overhead" like if without the hub we have 100%, with the hub we lose 1% to overhead and have 99% left to split, and if i add it to another hub I will lose another 1% overhead, but is that assumption right?
Are the power divided evenly among the devices? so if I have 5 connected to the hub, each will receive 20%? And what if one has "finished using" (like say I'm charging a iPhone and it's already at 100% / or say i connect to an external mouse but the mouse is switched off), does the power of the other 4 stay capped at 20% as long as the 5th one is attached?
Answer
The Wikipedia article will tell you everything you need to know, but the basics are that you can have a total of up to 127 devices, this includes the hubs themselves when daisy chained. Each device has available a specified amount from the port it is plugged into, not a division based on how much is plugged in. Each port will provide no less than 4.75 volts and no more than 5.25 volts and up to 500 mA to the connected device. A hub can supply no more than 500 mA in total load. If a device needs more than 500 mA, it needs to draw external power. If the hub is supplying power to multiple devices, the draw is divided amongst them as they require it (all devices start out as low-power (100 mA), but may change mode to high-power after and pull current as needed if available). If the hub is powered from another USB port and does not have external power, it will supply no more than 100 mA to any port at any given time.
USB as a battery charging specification works differently. If you plug your phone into your computer it will charge differently than when plugged into a wall or your car. When connected to a computer, you are bound by those limits above as it is treated as a connected device, but to a wall or your car it can pull up to 1.8 A (though 1.5 is pretty standard for dedicated charging ports).
EDIT: Updated post after reading specifications a bit more in depth.
ssd - Is it possible that solid state drives (or any faster drive) will make common applications faster even if they are cached?
I assumed that solid state drives are insignificant after, say, Firefox is fully brought up and no important disk activity after that is going on. However, I wonder if some kind of 'cached from the disk to the CPU' activity is going on that may make solid state drives (or any faster drive) better. Then again, I suspect that may be depended only on the Bus (or some kind of cache memory drives have). Hrm..
How to activate the free Windows 10 upgrade without actually using it?
I still have some reservations to upgrading to Windows 10. I'm fully aware that there is still a year left for the free activation but I might not choose to use Windows 10 for a bit longer than that. Now I'm wondering what needs to be done so I could still upgrade to windows 10 after that year is over.
If I understand things correctly:
- After July 29th, 2016 I won't be able to upgrade for free.
- Windows 10 upgrades stores the hardware signature (mainly motherboard) and is tied to that computer.
So I'm wondering if one could put in a different hard drive into the computer, install and activate Windows 7 on it, upgrade and activate Windows 10, pull the hard drive and replace the original hard drive. Would this work to ensure that Windows 10 can be installed for free on that computer after the year passed?
browser addons - Using vim as the editor for the It's All Text! Firefox Add-on
I am trying to use vim as the external editor for It's All Text! within Firefox. This works fine for standard http:// web pages, but when I try to use it within TiddlyWiki, 89 instances of vim are opened. I am guessing that the difference is that the TiddlyWiki page is a file on my local file system. I also created a simple html file and had the same problem. Is there a way around this problem?
From the comments:
I am on Windows Vista if that makes a difference.
Answer
Try the vimperator plugin for firefox. Hitting CTRL+i within a textarea form will vim start as external process. This works almost everywhere - at least where I tried.
linux - How to change user in WinSCP?
I'm using WinSCP to access Unix computers. How can I change user after I have logged into a Unix server using WinSCP?
E.g. I have personal account in Unix computer A. I can log into this computer using PuTTY and then change user to root user
$sudo /usr/bin/su - rootuser
How can I do the same thing using WinSCP? I don't know the password for rootuser
.
Can I provide RGB hex strings in an Excel worksheet for pie chart colors without using code?
Like user1813558 in his question "Change the pie chart colors" I would like to choose the colors that Excel uses for a pie chart (indeed for any chart) as I need them to be consistent with other data visualizations we have carefully produced so that a color-blind team mate can still join in data trawl sessions. But rather than write code I would like to do it in the Excel sheet. Is there any way I can put the color data down in the Excel worksheet, for example as a column of RGB hex strings like 7DFF7D, and point the chart at that column for its color choice?
Answer
What you would like to do is not possible without code.
The following VBA function can be used to set colors based on cell values for a pie chart in the active worksheet. The color values can be in an N rows x 3 columns range of decimal RGB values or an N rows x 1 column range of 6 digit hex values (where the hex number is a set of three 2-digit hex values in RGB order).
The function requires two arguments: a reference to the range of color values (A1:A5, for example) and the name of the pie chart. The chart name can either be a default name (such as "Chart 2") or a name given to the chart.
If the number of columns in the input range does not equal 3 or 1, or the number of rows does not equal the number of data points in the pie chart, the function returns #N/A! error.
A recolored chart will retain the new colors after the function is deleted from the sheet.
Option Explicit
Function SETPIECOLORS(colorRng As Range, chartName As String) As Variant
Dim colorArr As Variant
Dim myChartObject As ChartObject
Dim i As Long
Set myChartObject = ActiveSheet.ChartObjects(chartName)
' // Assign RGB decimal color values to array
If colorRng.Columns.Count = 3 Then
colorArr = colorRng
' // Assign RGB hex color values to array
ElseIf colorRng.Columns.Count = 1 Then
ReDim colorArr(1 To colorRng.Rows.Count, 1 To 3)
For i = 1 To colorRng.Rows.Count
colorArr(i, 1) = "&H" & Left(colorRng(i).Value, 2)
colorArr(i, 2) = "&H" & Mid(colorRng(i).Value, 3, 2)
colorArr(i, 3) = "&H" & Mid(colorRng(i).Value, 5, 2)
Next
Else
' // Number of columns in color range not equal to 1 or 3
SETPIECOLORS = CVErr(xlErrNA)
Exit Function
End If
With myChartObject
With .Chart.SeriesCollection(1)
If UBound(colorArr, 1) = .Points.Count Then
' // Set the colors of the pie data points
For i = 1 To .Points.Count
.Points(i).Interior.Color = RGB(colorArr(i, 1), colorArr(i, 2), colorArr(i, 3))
Next
Else
' // Number of rows in color range does not equal number of data points
SETPIECOLORS = CVErr(xlErrNA)
Exit Function
End If
End With
End With
SETPIECOLORS = True
End Function
The function can be installed by copying it into a new module inserted via the Developer / Visual Basic menu accessed from the Excel ribbon.
windows 7 - How can I block a program from accessing the Internet?
I really want to know how can I prevent a program to connect to Internet with Windows 7 firewall?
I have smart security nod32 business edition installed on my computer.
should i do this job with nod or there is a way in Windows Firewall?
Answer
Basically you do this to prevent a program from connecting to the Internet:
From start menu, search for "Firewall" and select
Windows Firewall with Advanced Security
Choose Outbound Rules from the tree at the left.
Choose
New Rule...
from the menu at the right.New Outbound Rule Wizard
opens. This is really easy now:a. Select
Program
as rule type.b. Select the program's EXE file.
c. Choose
Block the connection
.Choose the profile this rule applies to. If in doubt, select all three.
Add the descriptive name (you may want to delete this rule later).
You're done.
linux - Custom hotkey/shortcut to open/bring to front an app
I don't imagine this is built into the system, but is it possible to do it without too much hassle?
Say I open a specific program with a hotkey, and when I press that hotkey again, the program window is brought to the front.
I want to do this on Ubuntu 9.04.
Maybe with D-Bus? Any experts?
Update: Here's what I ended up with in case it's of help to somebody:
#!/bin/bash
if [ -f "/tmp/myterm.pid" ]; then
WID=`cat /tmp/myterm.pid`
xdotool windowactivate $WID
if [ "$?" != "0" ]; then
WID=""
fi
else
WID=`xdotool search --title "UNIQUE TITLE" | head -1`
fi
if [ "$WID" == "" ]; then
/usr/bin/gnome-terminal --window-with-profile=MYPROFILE "$@"
WID=`xdotool search --title "UNIQUE TITLE" | head -1`
echo $WID > /tmp/myterm.pid
else
xdotool windowactivate $WID
fi
Surely it can be simplified, but I'm no bash
wiz. Also, for my example to work, I created a custom profile in Terminal that applies a unique title to the window so it can be found later. The possibilities are endless!
Answer
The wmctrl
program is just what you're looking for (sudo apt-get install wmctrl
). You can use the wmctrl -a "AppTitle"
command to bring the app to the front. wmctrl -l
will list all available windows, so it should be easy to write a shell script that checks if your program is running and either launches it or brings it to the front. Then you can just bind that to a keyboard shortcut.
First save the following script somewhere, I'll use /home/jtb/code/bringToFront
. It takes two arguments, the first is what you would type at the terminal to launch the program, the second is a substring of the program window's title. If there is no constant unique string in the title then you'll need to do a bit more work to find the program's window.
#!/bin/bash
if [ `wmctrl -l | grep -c "$2"` != 0 ]
then
wmctrl -a "$2"
else
$1 &
fi
With the script in your current directory, run
chmod +x bringToFront
to make the script executable. Then make sure it works; to launch/focus firefox you could run./bringToFront firefox "Mozilla Firefox"
.Now we need to bind a shortcut key. Run
gconf-editor
and navigate the folder structure to the left to/apps/metacity/keybinding_commands
.Double click on the first
command
with a blank value, probablycommand_1
. Type the full path to the script and provide the two parameters, e.g./home/jtb/code/bringToFront firefox Firefox
.From the panel on the left, select
global_keybindings
, the next folder up. Find therun
entry matching the command you just defined, probablyrun_command_1
. Double click it and type the keyboard shortcut you want to use. Put the modifiers in angle brackets, e.g.
.F
Now Control + Alt + F will bring your firefox window to the front, or launch it if it's not already running.
wireless networking - How to automatically connect WiFi In Mint 18.3 KDE?
I install Linux Mint on a thumb drive for occasional in-home use as a convenient portable system that doesn't affect the native OS of whatever system I use it on. I'm not too worried about security in my location, and I want to boot and connect to my wireless router with passwords automatically entered.
This was no problem until I just loaded Mint 18.3 KDE. Previous versions would simply remember the WiFi password, although recent versions have required disabling kwallet. With v18.3, however, it took some mucking around to bypass Mint's protecting me from myself; for GUI users, they've buried access to the setting.
I'll post the solution I found as a self-answered question to save other users the headache. Any other solutions are also welcome.
Answer
This is the route to the setting that I found (there was no obvious route via the System Settings menu):
- Click the Networks icon in the system tray to bring up the network connections. Then click on the
configure network connections
icon in the upper right of that window (circled in the image below).
- That opens this window:
- Select the wireless connection and click
Edit
(circled on the image), which opens this window:
- On the WiFi Security tab, enter the password. Click the icon on the right side of the password and select
Store password and make it available for all users (not encrypted)
. That is not the default setting, and was the only selection that retained the password with kwallet disabled.
search - Searching for content in a large number of Excel files
I have 2500 Excel files. I need to output all rows which contain a certain string in a certain column. How can I do this? What if the certain string is not in a fixed column, but could be in any column?
Thursday, 28 November 2019
powershell - Replace app package on Windows 10
I recently updated to Windows 10 Home Build 10586. Some built-in apps, however, appear to have been corrupted. One example being MSN News:
I have uninstalled and re-installed these apps several times with reboots in between. I have uninstalled apps both via the start menu and via Powershell (Remove-AppxPackage
).
I am the only user account.
How can I force the store to replace app packages when reinstalling built-in apps?
Answer
Navigate to
C:\Program files\WindowsApps
(take ownership if you haven't already done so byRight-clicking on the app folder then left-clicking security tab -> change ownership -> select your user name -> apply -> ok
)Inside the folder search for "bing news" delete any file with
Microsoft.BingNews_2015.709.2017.3396_neutral_~_8wekyb3d8bbwe
or similar, then run the app.In the start menu,
right-click the app
and click uninstall.Finally go to store and reinstall the app and search for updates on the store.
BSODs and Prime95 failures
My computer is notoriously unstable. It blue screens all the time. I'm running Windows 7. Here's what's in the box:
- Intel Core i7 920 (Stock cooler, not overclocked)
- Gigabyte EX58-UD3R motherboard
- 6GB (3x2GB) OCZ Gold memory (set to 1333MHz, it has problems booting if I leave it at 1066)
- GeForce 9500 GT
- Antec 650W power supply
When idle it seems to run at between around 40 and 50 degrees Celsius, according to SpeedFan. I've run many memory tests, and none of them have come up with any problems.
Now I've received several messages when it Blue Screens:
- IRQL_NOT_LESS_OR_EQUAL
- Page fault when not paging (or something like that)
- Random addresses/registered
Unfortunately, they go by too quickly for me to take much from them.
I just ran Microsoft's hot fix for the first (though I'm not positive that my error is 100% the same as theirs, I don't know if I'm getting the 0x0000000A part), so I don't know if that will help or not, but if Prim95 is any indication, it won't, for the following reason:
When I run Prime95, 8 threads start up, and they all stop very quickly. I get the following errors in the results.txt file:
[Tue Feb 16 15:44:35 2010]
FATAL ERROR: Rounding was 0.5, expected less than 0.4
Hardware failure detected, consult stress.txt file.
FATAL ERROR: Rounding was 0.5, expected less than 0.4
Hardware failure detected, consult stress.txt file.
FATAL ERROR: Rounding was 0.5, expected less than 0.4
Hardware failure detected, consult stress.txt file.
FATAL ERROR: Resulting sum was 4050964008042496, expected: 2785959515376393
Hardware failure detected, consult stress.txt file.
FATAL ERROR: Resulting sum was 4.042840052791945e+056, expected: 3.789462128888016e+016
Hardware failure detected, consult stress.txt file.
FATAL ERROR: Resulting sum was 5.593535921577141e+247, expected: 1.208964328863723e+017
Hardware failure detected, consult stress.txt file.
When I looked at the stress.txt file, it suggested memory might be my problem, but as I said, I've run multiple memory tests (MemTest86, I think? It was a while ago), and no problems have been detected.
After running the hotfix, the test threads managed to stay running a little longer, and while my temperatures definitely rose, they never really got about 60C.
So, basically I see three problems:
- I'm running pretty hot. With the stock cooler, I idle close to 50 on some cores with the side of my case off. Putting my hand in front of the CPU fan, I don't really feel much of a breeze. Is this normal for the 920 stock cooler?
- I blue screen all the time (like 1-4 times per day).
- I can't seem to run Prime95 for more than a few seconds.
Can anyone point me in the direction of what might be going wrong here, and perhaps what to do to confirm/fix the problem?
Thank you.
Answer
First things first - Go to Control Panel > System (Windows Key+Pause/Break) and then under Advanced, you should see "Startup and recovery", click Settings and you can disable Automatic restart on system failure.
Next time a BSOD occurs, you can see what the cause is.
Also, you may want to see Blue Screen View, a very good tool to help you see previous Blue screen errors.
Now, As ~quack said, just because it passes some tests, doesn't mean it is good. If you ran it for a few hours, swapping the modules around and re-running again may make it quickly touch some places it didn't before - but really, unless you run memtest86+ for around (or ideally over) 48 hours, you will not have a good result.
Next, the errors you said are most commonly down to faulty/corrupt/bad memory, but can really be anything - the most likely reason is bad/dodgy device drivers.
If you are getting this every time you run Prime95, I would highly recommend you try unplugging EVERYTHING from your machine other than power, video and keyboard (and mouse, unless you are confident of using the machine without one). Now, go to safe mode and try running Prime 95 again. This is the best way of testing if it is a driver issue - apart from actually reinstalling Windows from scratch and not installing any drivers!
If you are still seeing random problems and Memtest86+ really is not showing errors, it is most likely a problem with the motherboard or even CPU, however, this can be very hard to diagnose.
As for temperature - the lower the temperature, the slower the fan speed - your CPU is very cool and there is nothing to worry about.
How to export a specific registry key to a text file using command line
How can I export specific value from the registry to a text file using the command line?
For example, I want to export Hkey_local_Machine\Software\mcafee
to a text file in C:. I just need the key – that's it.
I tried with reg export
– it's giving everything, but I just require the key of the partiular thing.
Get rid of chrome new tab page ad
So, recently, on the Chrome new tab page, the message "Get a Chromebook for the holidays" has started to appear. (Others have witnessed similar behavior)
I want to know how I am supposed to get rid of it. Clicking the "X" is not a permanent solution.
windows 7 - How can I delete a folder with "illegal" characters?
I plugged my USB flash memory stick into a Mac and it gained some unwanted hidden folders. (See the question Prevent MacOS from making .* and ._* files for prevention.)
I'd now like to remove these from my drive but I ran into an issue. Inside the fseventsd
folder is a subfolder that is not shown unless I disable "Hide protected operating system files" in folder options. I am then shown a folder icon with no name, and attempting to delete it results in no action and no error. Attempting to open it results in the error:
E:\fseventsd\ is not accessible
The filename, directory name, or volume label syntax is incorrect.
So I took a look using command prompt:
I must admit, had I not known the parent folder was from Mac OSX I would have strongly suspected a virus, because the folder name renders as a smiley face in ASCII.
Apparently this is ASCII character "01":
Any commands I issued in Command Prompt resulted in various syntax errors as well. I decided to try Powershell.
Unfortunately 1) I'm not very experienced with Powershell, and 2) it appears to have similar difficulty with the weird folder name. I got the following error in Powershell just trying to list the parent directory contents:
Get-ChildItem : Illegal characters in path.
How can I delete this folder?
Answer
I was able to "fix" this by running chkdsk /f
on the drive. It converted the fseventsd
folder to a file which was easily deleted. However, I don't know if this "fix" was because the subfolder appeared broken to chkdsk, or if there was something else on the volume that allowed this to work.
Offering this as an answer in case it works for others.
boot - Where can I find good documentation on "msconfig" and "services.msc" for Windows 7?
Running Windows 7
I'm trying to boost the startup speed of my computer and I'm going through "msconfig" and "services.msc" to disable some applications from starting up automatically when the computer turns on.
There are some good sites that document the entries found in the "Processes" tab of the task manager. You can find out if they are safe to kill, who the manufacturer is, and what the process in question is used for.
Are there any sites that list startup processes &| services that are safe to kill? For example, there is an entry in msconfig that just says "Computer Browser" - pretty vague, but seems like something to not kill. On the other hand, there is an entry in msconfig that says "Extensible Authentication Protocol" - pretty specific and seems like it shouldn't be killed, but how can I know for sure?
Does anyone know if there are any websites documenting the "killable" items listed in both msconfig & services.msc?
How to use two audio devices simultaneously with Windows 7?
I have an audio connector on board (Asus P8H67-I) and an USB audio card (Teufel). How can I use the two devices simultaneously?
As far as I can see I have to set one device to the standard output device. I am looking for a way to set both to the standard output device in order to hear on both the same sound.
Any ideas?
Answer
Windows does support multi streaming audio.
Microsoft calls it stream routing.
This actually existed back in Vista. . .
http://louisgale.blogspot.com/2009/08/live-messenger-and-default.html
http://laptopsall.com/configuring-multi-streaming-playback-for-realtek-audio-on-intel-desktop-boards
For a hands on example, play something on Youtube. Fire up Windows Media Player. Go to Tool, Options, then click on the Devices Tab. Doubleclick the speakers and switch the output to, say from Back Speakers to Front Headphones. Now you have Youtube through the Back connections and an MP3 going on the front headphones.
Media Player Classic along with VLC also support this feature, again, which was available since Vista. In MPC, it's an obscure listbox on the bottom of the Output options. VLC, switch to Advanced and look under the Audio tree.
As long as your Audio drivers are updated and the Application supports it, then you are good to go. Some programs can be fooled into playing onto another output device by switching the default device after you've hit play. . .
windows - Mouse forward/back buttons reversed
For some reason the forward and back buttons on my mouse seem to have been swapped round. I'm inclined to blame the firefox 6 update for this, but see no way to put them back the way they were?
Run a script on start up on Windows 10
On previous versions of Windows I have used the below technique to run a batch file on Windows startup.
- Create a shortcut to the batch file.
- Once the shortcut is created, right-click the shortcut file and select Cut.
- Click Start, then Programs or All Programs. Find the Startup folder and right-click that folder, then select Open.
- Once the Startup folder is opened, click Edit in the menu bar, then Paste to paste the shortcut file into the Startup folder. If you do not see the menu bar, press the Alt key to make the menu bar visible. Any shortcuts in the Startup folder will automatically run each time the user logs in to Windows.
I have been unsuccessful in finding how to do something similar on Windows 10.
Any ideas?
Answer
The startup folder is still there and functions as normal.
To access it, press Windows+R, then type shell:startup
.
You should be able to do what you were previously doing in Windows 7 from there.
xterm - What is Arch Linux's default terminal?
Using the command echo $TERM
, I get the output 'xterm'. However, I have not done anything to install the X Windowing System, and as far as I know, Xterm cannot run without it, and Arch does not install it by default. (Furthermore, there isn't any manpage on xterm, and I would think that if I actually had xterm installed, it would have a manpage).
So is the default terminal for Arch Linux really Xterm? If so, how is it running without X? If not, why does the $TERM
variable contain 'xterm', and what is the default terminal?
Answer
When you log in to the console without X11, you are using the Linux built-in "virtual console". It's built into the kernel and its terminfo name is linux
, which is what you should be seeing in $TERM
.
If your $TERM
has anything else, carefully check your configuration, including:
- the agetty lines in
/etc/inittab
(they should saylinux
at the end1) - system-wide shell startup scripts
/etc/profile
,/etc/profile.d/*.sh
/etc/bash.bashrc
(if using bash)
- your own shell startup scripts
~/.profile
,~/.bash_profile
,~/.bash_login
,~/.bashrc
1 Certain Arch Wiki pages suggest configuring agetty in inittab to use xterm
or even xterm-256color
. This is nonsense.
mouse - How does a Logitech scroll wheel detect movement?
I just replaced my scroll wheel in my mouse, a one minute repair. But now I've seen something that can't be unseen.
Logitech scroll wheels apparently function using magic.
It freely rests on three buttons that detect left, right, and straight down presses. But the wheel itself is not electrically connected to anything whatsoever. It's plastic resting on a spring.
How does the mouse know when I'm scrolling? And why was it affected by dust and gunk?
Edit: and how does it detect which direction you are scrolling?
Answer
There's a diode (probably infrared) and a receptor, one on either sides of the wheel, soldered directly into the green PCB. Wheel is SPOKED, and by turning it you interrupt light travelling from the diode to the sensor. No magic there.
Oh, and dust sitting in there can permanently block sensor from any light coming from the diode, so there's no way for it to register interruptions, that's why the wheel appear to not work.
linux - Downloading multiple files with wget and handling parameters
How can I download multiple files using wget? I also want to rename the files. Here are the commands I'm running one by one (copy/paste on terminal):
wget -c --load-cookies cookies.txt http://www.filesonic.com/file/812720774/PS11.rar -O part11.rar
wget -c --load-cookies cookies.txt http://www.filesonic.com/file/812721094/PS12.rar -O part12.rar
wget -c --load-cookies cookies.txt http://www.filesonic.com/file/812720804/PS13.rar -O part13.rar
wget -c --load-cookies cookies.txt http://www.filesonic.com/file/812720854/PS14.rar -O part14.rar
........ and so on..
What can I do to download all these files one by one?
Wednesday, 27 November 2019
user interface - How to permanently zoom in Firefox without using addons?
How can you permanently zoom in Firefox without using an add-on?
Does Firefox have a zoom option similar to Internet Explorer, Chrome & Opera's zoom to x% option?
Answer
Notice: These settings may not work with version 29 or newer.
Open Firefox and type about:config
into the address bar and search for "zoom".
In the search results, change two settings as below.
browser.zoom.siteSpecific false
zoom.minPercent 150
The value of zoom.minPercent
must be an integer.
partitioning - what's the changed situation with partitions on ssd?
i've heard it said- why partition with ssds
i'm wondering why they would say that. Is the situation different from with spinning disk style hard drives.
The reasons with spinning disk drives, were
-smaller partitions are quicker to defragment
-could be quicker to format (though there is quickformat!)
-organization separating data and system onto separate partitions, and can wipe the system partition.
I know somebody may look at those reasons and still not partition a drive. But I am interested in what the reasons are, with partitioning an SSD drive, how the situation differs if at all?
Somebody suggested why not buy a few small SSDs. Though surely the same logic would apply to partitioning non-SSD drives? And surely with either, one is limited by the number of SATA ports.
And is the issue of partition alignment something that is relevant to both SSD and non-SSD? i've only heard of it recently, in SSD times.
Answer
The reason for using a partitioning scheme would be to allow for the presence of a Master Boot Record. Since one is only needed on the first hard drive, subsequent hard drives can have only a single volume taking up the full disk.
Partition alignment isn't a big deal in platter drives since they're so slow regardless that it really won't make that much difference.
windows - Using Romanian keyboard with gVim
I'm using gVim to type in a journal paper that contains a lot of occurences of the unicode characters U+0219 "s with comma below" (È™) and U+021b "t with comma below" (È›).
Both encoding
and fileencoding
are set to utf-8
, and the GUI font I'm using, Consolas, clearly supports these characters, yet Vim shows them on screen as question marks. That wouldn't bother me too much, except it saves the file to disk with the question marks as well!
Update: Looks I can paste the character into Vim from clipboard, I just can't type it. I'm using the "Romanian (Programmers)" keyboard, and È™ is bound to AltGr+s, or Ctrl+Alt+s. Could there be some keybinding conflict with gVim on Windows?
Answer
I think :he mbyte-keymap
may be the answer to your problem - this has an advantage that normal mode is not using the alternative layout.
Surprisingly there is no Romanian keyboard shipped with vim, so you can use one from here
Then just set:
set keymap=romanian
license - Windows 10 upgrade offer: Once installed is it tied to the one machine?
As many people, I have the icon in the task bar offering me to register for the upgrade to Windows 10. However, I plan to build a new machine later this year and I'm concerned that if I upgrade to Windows 10 when it's release, is my free year going to be tied to my current motherboard/CPU (or however the machine is identified)?
Answer
I'm concerned that if I upgrade to Windows 10 when it's release, is my free year going to be tied to my current motherboard/CPU (or however the machine is identified)?
This entirely depends on what type of license you have. OEM machines that came with Windows 7 or Windows 8.1 are tied to that machine. Once you upgrade to Windows 10, that installation also, is tied to the machine. Microsoft considers the "machine" to be the motherboard.
If you have Retail license of either Windows 7 or Windows 8.1 this provides you the right to transfer the license, a reasonable amount of times ( i.e. not unlimited ) to other machines, rights remain unmodified and continue through to Windows 10 per the Windows 10 EULA.
Transfer. The provisions of this section do not apply if you acquired the software as a consumer in Germany or in any of the countries listed on this site (aka.ms/transfer), in which case any transfer of the software to a third party, and the right to use it, must comply with applicable law.
Software preinstalled on device. If you acquired the software preinstalled on a device (and also if you upgraded from software preinstalled on a device), you may transfer the license to use the software directly to another user, only with the licensed device. The transfer must include the software and, if provided with the device, an authentic Windows label including the product key. Before any permitted transfer, the other party must agree that this agreement applies to the transfer and use of the software.
Stand-alone software. If you acquired the software as stand-alone software (and also if you upgraded from software you acquired as stand-alone software), you may transfer the software to another device that belongs to you. You may also transfer the software to a device owned by someone else if (i) you are the first licensed user of the software and (ii) the new user agrees to the terms of this agreement. You may use the backup copy we allow you to make or the media that the software came on to transfer the software. Every time you transfer the software to a new device, you must remove the software from the prior device. You may not transfer the software to share licenses between devices.
windows - Sharing iTunes library (Mac/PC)
I recently got a MacBook and installed Windows 7 on it. Being a .NET developer and a Windows lover (I'm sorry, it happens), I want to keep my iTunes library on my NTFS partition, but have both Windows and Mac read the library so I can sync/develop for the iPhone on Snow Leopard.
Is there an app that does this?
What happens if a video card cannot get enough power?
I am wondering what will be the symptoms if high end gaming video card does not get enough power because the PSU is not powerful enough. Some high end video cards list their requirements as lets say 550W but they work with PSU of 400W.
So what happens in this case? Will the PC shut down undr load or maybe the hardware will not perform to its maximum (for example will not produce as many FPS)?
Answer
You risk overdrawing the PSU and damaging it. It can also cause other components to not get enough power or deal with erratic power from an overloaded PSU, so unrelated things may also start to act up. Better quality PSU's are probably going to be more robust than lower quality cheap OEM provided ones.
A video card or other component may be say it needs a 550w power supply, and it probably does only when fully loaded. So you may not experience problems on power on, but only after playing a game or something else that stresses the GPU.
Specific symptoms include:
- lockups
- BSODs
- graphical corruption
- display goes black
You can try "burning-in" your card by running a benchmark utility such as FurMark3d or similar for an extended time, giving problems a chance to surface. But don't do it if you know your PSU is underrated. Get a new PSU.
command line - How to access efi partition on windows 10?
I am having trouble accessing the EFI partition on windows 10 I tried this method in cmd (I used Administrative privileges ):
open cmd as admin...
diskpart
sel disk 0
sel part 1 (efi part)
assign letter=b
exit
taskkill /im explorer.exe /f
explorer.exe
But it is not working since windows 10, I used this method fine on 8.1.
this picture shows the error I get when I try to access the partition
Answer
The answer is by @pat2015 :
Interestingly I find that the mounted EFI drive is accessible from the ‘Browse’ button from Task Manager -> ‘Run New Task’ You can then perform basic operations possible with Context Menu (Copy/Paste etc) and even when you run other apps with Admin Privileges e.g. Notepad.exe it can also access the drive from its file menu. The issue seems to be with Explorer.
Thunderbird: Folder listing suddenly empty
Yesterday I used thunderbird and everything was fine. Today I started thunderbird and it looked like this:
If I delete my ~/.thunderbird folder and recreate my email account everything works fine again, but I am not that keen on restoring all my settings manually.
Any suggestions for fixing?
Ubuntu 11.04
$ uname -a
Linux thorus 2.6.38-12-generic #51-Ubuntu SMP Wed Sep 28 14:27:32 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux
Update
I figured that the folderTree.json file in my profile directory looks broken. It is some binary stuff, most definitly not json. Deleting that file improved the situation: Now the folder tree is available again, but unfortunatelly thunderbird does not recreate the file and the folder tree is always in fully collapsed state when I start thunderbird.
virtualbox - Will Windows 8.1 remain activated on a copy of a .vdi virtual machine file, if I have stopped running the original .vdi virtual machine?
I have two computers running Ubuntu.
In one computer, I created a Windows 8.1 virtual machine in VirtualBox as a .vdi file. I activated it using a product key obtained from my previous school's Dreamspark program. I haven't run the virtual machine for a while.
Now I want to use the Windows virtual machine on the other computer under VirtualBox (Or Virtual Machine Manager). Can I just copy the .vdi file from the first computer to the second computer, and run it there? Will the Windows 8.1 on the copy of the virtual machine still be activated, as long as I won't run the original .vdi virtual machine on the first computer?
Thanks.
ssd - Can I run a virtual machine from external USB drive?
A question regarding how to setup my VMs on internal/external disks. First, here's my setup:
- Host OS: Windows 10
- Processor: i7 5600U
- RAM: 16 GB
- VMware Workstation Player (Licensed)
I have 3 VMs so far and I'm soon getting a 4th and there's not enough space on my internal SSD anymore, so I need an external disk to place some of them on. I have a laptop with USB3 ports and a dock for the laptop with an eSATA port. I read about the speeds of both, and 5Gbps vs 6Gbps doesn't look like that much of a difference to me (but I'm not an expert on this) - and the only other USB devices connected are cabled mouse and keyboard.
What I'm using the VMs for: I'm a developer, and the different VMs are for different development environments.
- 1st VM is running Windows Server 2008 with Visual Studio, SQL server and K2 Blackpearl.
- 2nd VM is running some Windows Server 2012 with Visual Studio, SQL server and BizTalk (among other things I don't know yet - this is the new VM I will get soon)
- 3rd VM is running Ubuntu and will be used for Python development (probably in PyCharm)
- 4th VM I haven't gotten around to yet - I was employed about a month ago :-)
My questions:
- Is it possible to run a VM from an external HDD? (Or is SSD a must here?)
- Will USB3 suffice or should I get one that also supports eSATA?
- Is it better to store the less frequent used VMs on the external drive and then move them to the internal drive, when I need to use it? This will require me to move a VM from internal drive to external first, hence this question.
- Is it even possible to run a VM from an external drive without major performance loss?
I think that was it for now. I look forward to your answers.
Best regards,
Joakim
For anyone who finds this post and wants to know the result: I had some doubts about this pre hand, and I would not recommend this setup for any developer. The boot time is horrible and starting apps like Visual Studio takes at least 3-4 times as long time.
My advice: Only use this solution if you have no alternatives.
Answer
The answer depends a bit on what the VMs are supposed to do. For "paperwork" like writing and reading you'll be fine. "Major performance loss" is not a well-defined value.
For most people it should be okay. If you find yourself to be an extremely impatient computer user, get the fastest equipment you can, I would even suggest replacing the internal SSD with a bigger one. A 2 TB SSD is now on the market, which may or may not be too expensive for you (700-800$).
For programming, you likely won't get much more bang when writing code. You might get a performance boost when compiling. If you're not the type to do stuff in parallel while your code is compiling, get the fastest equipment you can.
The TLDR is: If you can afford it or if you don't have HDD lying around, get an SSD, internal or external (eSATA or USB 3). When in doubt, get the good stuff.
- Is it possible to run a VM from an external HDD? (Or is SSD a must here?)
Yes, it is possible, but you will likely have some performance loss. The VM should run okay as long as you don't have operations that require a lot of file writing. Also, the smaller the VM, the better. If you have a 50-60 GB Windows VM, it will be very slow on an external 5400 HD with USB 3. I am speaking from experience here. You can still do stuff, but it will take a while.
Running more than one VM on an external HDD at a time may bring a severe performance loss. Consider using two external HDDs for that scenario.
- Will USB3 suffice or should I get one that also supports eSATA?
USB3 should be fine, at least it was in the cases where I used them. Faster is better. If you haven't bought the external HDD yet, you might want to go for eSATA because you never know what you'll use your spare USB ports for. (You may want to add a 2nd external drive for back-up purposes.) With an HDD, you might not get much more performance from eSATA because file-writing and -reading speeds on a spinning platter disk are the limiting factor.
Also try to get an SSD or at least a 7200 rpm HDD for the external drive, if you can still find one. Or build one from an external case and an external USB enclosure. If you can't afford an SSD, a 7200 will cut file transfer times by a few percentage points.
- Is it better to store the less frequent used VMs on the external drive and then move them to the internal drive, when I need to use it? This will require me to move a VM from internal drive to external first, hence this question.
I think you should keep the VMs that will do lots of heavy lifting like file-writing and computing intensive stuff on the internal drive, irrespective of how often you use them. Shifting them can be quite a pain. Copying a 20 GB VM from internal to external HDD will take about 6-7 minutes at 60 MB/s. Internal to external SSD will be substantially faster. If you find the performance from the VMs on the external disk acceptable, moving them around might not be necessary. You can cross that bridge when you get there.
- Is it even possible to run a VM from an external drive without major performance loss?
See 1., yes it is possible for normal to medium computer work, if the VM is small. If you do graphics design or lots of file transfers, there may be a severe performance loss.
For your programming needs I would suggest on data gathered elsewhere that you get an SSD (What is more important CPU or RAM for compiling large software, e.g. bootstrapping gcc?, http://www.overclock.net/t/997361/compiling-and-cpu-usage). Though there are some dissenting opinions (https://stackoverflow.com/questions/15199356/speed-up-compile-time-with-ssd). Again, when in doubt, get the good stuff.
Edit: Januar 5th, 2016 - added some information due to recent experiences
Tuesday, 26 November 2019
networking - How can I use a computer as a router and send all client traffic through anonymous proxies?
Is there a way that I can setup a spare box as a router on my network, and route client traffic through a proxy in order to hide my location?
Specifically, I would like internet traffic to/from my Roku Box to be routed via proxy, but there is no proxy support built in to the Roku. So I would like wire my Roku directly my computer's second NIC, and force all traffic through a proxy.
What kind of software and hardware setup will I need? I currently have a spare machine with two NICs and Windows XP. I have tried using the TOR network, and was able to successfully setup internet connection sharing, but was unable to figure out how to force client HTTP traffic to use the proxy.
What type of software setup do I need?
What program do you use to edit file associations in Vista and Windows 7?
We all know that Vista and Windows 7 doesn't let you specify custom extensions or customize them to your liking. What program do you use to edit file associations in Vista and Windows 7?
Just to be more clear, I'm looking for a program which lets you:
- Create new extensions (I am aware of the Open With > Set As Default).
- Customize the Icon
- Customize the file type name
- Allows the creation of custom actions
- Repair any non-working extensions
Presently, the Windows Vista/7 extension manager doesn't let you do any of those actions.
Answer
Default Programs Editor was created for this purpose! From the site:
File Type Settings:
- Add, Edit, and Delete context menu items
- Edit file type information (such as icon and description)
- Change an extension's associated file type
It also does Autoplay handler editing, and Default Programs editing. And it installs as a Control Panel applet, which makes it discoverable from Windows Search, so you can forget about it until you need it.
Also, it doesn't require administrative privileges for most operations (but it is UAC compatible).
(In the interest of full disclosure, I wrote this program!)
How to prevent additions to Chrome search engines (not just default)
This question is not about how to protect the default search engine in Chrome (which is, unfortunately, the only advice I can find when I try to search for the answer to this).
I use and edit the full list of Chrome search engines regularly:
chrome://settings/searchEngines
When I go to the list, there are usually many search engines added for sites that I have visited, but have not added to the list, and I regularly have to clean this list out. I don't know if the site is adding itself to the list or if Chrome is making some executive decision for me for sites that I visit regularly, but I'd like to keep it from happening.
Is there a way to only allow manual additions to the search engines list?
Answer
There is an extension that prevents additions to the list:
Unfortunately, Chrome doesn't appear to offer a built-in way to disable this.
"You can't disable this feature. Google wanted to make things simple so that users don't have to manually add search engines. Power users might not like this feature, but there's no way to disable it."
Source: Google Chrome Help Forum : How do I disable automatic add of new search engines?
64 bit - WIndows 7 64 bit reporting 3.00 gb usable memory with 4.00 gb installed
Possible Duplicate:
How to enable 4GB in my Windows 7 64 bit?
I have a computer that I have upgraded to Windows 7 Professional 64bit. It has an intel D945GB1 motherboard, Pentium D Dual core processor, nVidia Quadro FX 580 video card, 4 sticks of DDR2 1 GB memory. In the BIOS, I see all 4 sticks of memory. The Resource Monitor shows 1027 MB "Hardware Reserved".
I would try to get with intel about the motherboard, but it was made for Gateway's Business division which is no longer around, so I have no resources to tap into there. I cannot find if there was an update to the BIOS to fix the problem. The computer was originally sold to me as an XP Pro machine (32 bit) with 2 GB memory. The Upgrade Advisor indicated no problems like this.
When I remove the video card and run on the onboard video, the Hardware Reserved goes down to 780 MB or so. When I disable the onboard video, it goes back to 1027. In the memory table in device manager, I see from C0000000 to F0000000 (about 805 meg) used by PCI Bus in one block, but cannot find what on the bus is doing with this. I cannot find memory remapping in the bios, the max memory in msconfig is UNchecked, I have upgraded what drivers I can find, I have tried everything I an think of.
Any ideas?
What is the secondary CPU Usage Graph line in the Windows 10 Task Manager
I was looking at the task manager in Windows 10 and for the first time noticed a secondary dashed line below the solid? What does this line indicate?
Answer
That looks like the kernel time graph. Right-click the graph and see if this option is ticked.
Kernel time has been available for a while but it was more hidden.
Seems it was available from at least Windows XP : https://blog.codinghorror.com/everything-you-always-wanted-to-know-about-task-manager-but-were-afraid-to-ask/
malware - How do I clean up virus induced hidden files and disabled everything?
I'm working on a Windows XP computer that had the unfortunate experience of being infected by mal-ware that pretty much disabled everything. I was able to clean the computer using a combination of offline tools (MS Defender Offline, etc...) Although the computer is clean, I can no longer see any files, right click on the desktop, start task manager, etc... I know how to fix all these problems by hand including setting the file attributes and editing the registry but I am hoping to save myself hours of searching for every problem. Not to mention the unwanted problems that can occur when you unhide and unsystem files that weren't meant to be visible. Is there a tool somewhere that will reset all the restrictions in the registry to default and unhide only those files that shouldn't be hidden all in one crack?
Answer
For the hidden files: run ATTRIB -h c:\*.* /s /d
. It won't reset system files though. I would then run Malwarebytes AntiMalware to get the task manager, desktop and other security settings working properly again
How do I set the default CJK font on Windows 7?
I dislike MS Mincho: it's too thin, doesn't get anti-aliased, and has an excessive amount of hooks.
Unfortunately, anything that is full-width gets rendered in MS Mincho by default on any program.
I've been looking all over the place, including in the Microsoft IME settings, to no avail. Where can I change the default CJK font from Mincho to something else?
Answer
There's no registry key to do this; I believe it's hardcoded.
So I settled with MacType, which hooks to processes and overrides ClearType.
One feature it has is to allow you to override/replace specific fonts, including CJK ones, with other fonts, or to just turn on regular ClearType for those specific fonts.
windows 7 - How can I stream video from my XP sp3 desktop to my win 7 laptop?
I would like to stream media from my XP sp3 desktop to my Win7 laptop. I currently have Windows Media Player 11 on both machines. The XP one is set up for the media sharing service as far as I can tell. I have also set the 'Play To' option to my Win 7 machine on the XP WMP.
However, the only way I've been able to 'stream' is to simply tell my Win7 WMP to add a network folder to its libraries. This seems to work over the wifi but it does stutter a touch, even with a 20 second buffer. The stuttering also appears randomly, maybe 4-5 times during a 22 minute show.
I feel like I'm doing something wrong. Is this setup OK or am I missing something?
Answer
You may try VLC:
Windows 8 Pro, Windows 7 Pro downgrade rights and Windows 10 upgrade rights
I have two genuine Windows 8 Professional product keys (one 32-bit, one 64-bit, though I think they work equally). Non-OEM.
I assume these have downgrade rights to Windows 7 (?)
Is that indicated to expire? If I install Windows 8 Pro (with said key) on a pc, then use upgrade rights to Windows 10, will I then have downgrade rights from 10 to 7 on that PC?
If so, what will happen to the 8 Pro product key, will it be void? Is downgrade rights to Windows 7 now locked into that computer?
Basically, I have no interest in Windows 8/8.1. So I would like to lock in a Windows 10 license, but perhaps not if I loose the (Windows 7) downgrade rights for the product key I need to use..
Old pop-up notifications in Windows 10
Windows 10 pop-up notifications are terrible and slow. Is there a way to replace them with old Windows 7/8 notifications? I'm pretty sure it's possible since I did pretty much the same thing for sound mixer.
Windows 10 notification:
Windows 8 notification:
Answer
Winaero posted a hack to enable the old Balloon Tips again:
- Open Registry Editor.
- Go to the following Registry key:
HKEY_CURRENT_USER\SOFTWARE\Policies\Microsoft\Windows\Explorer
- Create a new 32-bit DWORD value named
EnableLegacyBalloonNotifications
and set its value data to 1.
- restart the PC.
Now you should have the old popups again.
That the Ballon Tipps is show in the left side is a bug, which is fixed since Build 10586.420 (KB3163018). Here is the changelog:
Fixed an issue that was causing balloon tip notifications to always appear on the upper left side of the screen.
To get the update just check for Windows updates in the settings app.
windows 7 - How to download favicon from website?
When you browse a website, the "favicon" icon shows up in the tab or next to the URL (or next to the bookmark).
If I want that graphic, is there a way to download it directly from the site? I'd prefer to download it directly from the web, but if all else fails, I'll dig it out of wherever it is stored on my computer (Windows 7, Firefox 3.6.6).
Answer
Studiohack has the "thorough" approach but heres a short hack:
- Enter the domain name like
https://superuser.com/
(must end with '/') - Add
favicon.ico
to the end - Press enter (this should be in the URL:
https://superuser.com/favicon.ico
) - Right click on the image and click "save image as"
linux - Gateway Server Jump Bastion Host Local Setup
I want to ssh to a remote private host using an intermediate (bastion, jump, gateway) server. This command works fine:
ssh gateway ssh private
With this ~/.ssh/config setup:
Host gateway
User gateway-user
HostName XX.XX.XX.XX
RequestTTY force
How can I implement this in my ~/.ssh/config? I've tried numerous iterations of ProxyCommand with no luck. I want to use the identity file located on gateway host to access private hosts. I want to be able to do:
ssh private
I am aware of the technique described here, but it requires my public key to be on all the private hosts, but I don't want that:
http://www.lorrin.org/blog/2014/01/10/one-liner-ssh-via-jump-box-using-proxycommand/
Answer
First, configure your ssh keys on the gateway so you can ssh to private. Then on your client, create a separate private/public key pair that you use to authenticate on the gateway. E.g. ssh-keygen -t rsa -f id_gateway
.
Then on the gateway, use the command=
syntax in your authorized_keys file. For example, your entry might look like this:
command="sh -c 'ssh private ${SSH_ORIGINAL_COMMAND:-}'" ssh-rsa AAAAB3....
Search the sshd manpage for command="command"
for more info. Be sure to add the id_gateway.pub key to this line. Then in your .ssh/config
on your client, add an entry like this:
Host private
User gateway-user
Hostname xxx.xxx.xxx.xxx
IdentitiesOnly Yes
IdentityFile ~/.ssh/id_gateway
Now, from your client you should be able to ssh private
and get directly in. This even works for scp
and sftp
.
Extra Credit
If you want to use this for multiple servers, but only want to manage one public key on the gateway, you can use the following trick. sshd
by default only allows certain variables to be received from the local environment. One of these is LC_PAPER
which is rarely used for anything. So we can use it to pass the server's hostname as follows:
First, change the public key entry to
command="sh -c 'ssh $LC_PAPER ${SSH_ORIGINAL_COMMAND:-}'" ssh-rsa AAAAB3...
Then on your client, add a function to your .bashrc
file (or whatever shell you use) that looks like this:
ssh_proxy() {
LC_PAPER=$1 /usr/bin/ssh $*
}
Then make an alias to if you want:
alias ssh=ssh_proxy
Finally, add Host
sections to your .ssh/config
like the one shown above. for example:
Host private2
User gateway-user
Hostname xxx.xxx.xxx.xxx
IdentitiesOnly Yes
IdentityFile ~/.ssh/id_gateway
Now you should be able to do ssh private
and ssh private2
with just the one public key on the gateway.
How do I replace-paste yanked text in vim without yanking the deleted lines?
So I usually find myself copying text from one point to another while overwriting old text where the new is pasted:
blah1
newtext
blah2
wrong1
blah3
wrong2
blah4
Suppose I visual-mark newtext
and y
ank it. Now I select wrong1
(which could be anything, not necessarily just a word) and p
aste the newtext
. However, if I now do the same with wrong2
it will be replaced with wrong1
instead of newtext
.
So how do I keep the text that is in the buffer from being swapped with the text that I am currently overwriting?
Edit 1
Although I quite like the reigister suggestions (I think I will start using registers more, now that I discovered the :dis
command), I am going with a modification of jinfield's answer, because I do not use the swapping mode.
vnoremap p "0p
vnoremap P "0P
vnoremap y "0y
vnoremap d "0d
does the trick perfectly.
Edit 2
I was too fast; romainl's solution is precisely what I was looking for, without the hack in Edit 1.
Actually, vnoremap p "_dP
is enough!
So, changing accepted answer.
Answer
I have these mappings in my .vimrc:
" delete without yanking
nnoremap d "_d
vnoremap d "_d
" replace currently selected text with default register
" without yanking it
vnoremap p "_dP
"_
is the "blackhole register", according to :help "_
:
"When writing to this register, nothing happens. This can be used to delete text without affecting the normal registers. When reading from this register, nothing is returned. {not in Vi}"
Monday, 25 November 2019
windows 7 - How to select default network interface for internet?
I have 2 network interfaces. Both use DHCP to obtain ip address. First provides internet directly and second uses PPPOE connection. How to select which connection windows will use to connect to internet? I need both links to be enabled and want one with PPPOE to be my default.
P.S. I understand I can do it using console and route
command but I want windows to do that automatically.
Answer
Go in to your network adapter properties page for the non-PPPOE device, from there click on Internet Protocol Version 4
and go to Properties
, from there click Advanced
to get the following window.
Un-check Automatic metric if it is checked and enter 100 for the value of the 'Interface metric' box.
That value should be high enough to make your computer prefer the PPPOE link if the PPPOE link has automatic metric set.
If you are doing IPv6 you will need to set the same value in the Internet Protocol Version 6
properties page too.
boot - Run Linux dist from bootable USB on Surface Pro 2
I'm having issues booting from USB on my Surface Pro 2 with win 8.1 and UEFI. Tried creating bootable USB using LinuxLive and a Linux dist. Also tried creating bootable USB with Easy2Boot, and adding Linux dist. I've tried Rufus too. They are partitioned as FAT32. It's like the USB is skipped. Nothing happends. I've tried disabling Secure Boot. There's no legacy option in UEFI setup. Tried different sub solutions to the two main ones I've mentioned. I'm only interested in running the Linux dist. Not install it. What could it be that is hindering me in booting from USB? I've tested the USB in another laptop, where it works fine.
Br
Frank
linux - Meaning of netstat output?
When I type "sudo netstat -an", this is part of the output I get:
Proto Recv-Q Send-Q Local Address Foreign Address State
tcp 0 0 192.99.202.17:39922 23.82.16.66:29842 TIME_WAIT
I am confused as to what the first line is saying.
Is it saying a server from 23.82.16.66 is connecting to this server through port 29842, or port 39922?
How do I know it's an incoming connection from that IP, as opposed to an outgoing connection from my server to that IP?
I'm running CENTOS 6.7, if that matters.
Maximize a window on to dual monitors in Windows?
I have dual monitors and I want to span my current window so that it appears as one giant window on both monitors. Does anyone know how to do this natively in Windows?
4k resolution - Slightly moving high dpi mouse prevents executing single and double clicks normally on 4k laptop
Problem is only on new 4k 17'' laptop. I use Windows 10. I use: UtechSmart Venus Gaming Mouse RGB Wired, 16400 DPI High Precision Laser Programmable MMO Computer Gaming Mice ( https://www.amazon.com/gp/product/B00FNKMVUO/ )
If I slightly move mouse between push down of mouse button and push up or between first and second clicks of double click then mouse does not execute single and double click respectively. When I use same mouse on old laptop (non 4k) and it behaves well but on my new 4k laptop one slight movement of mouse prevents it of executing of single and doable click which is very annoying.
Question: How can I fix it?
Answer
There are registry keys to change the double click response area.
Description:
The mouse double-click operation is done in a specific area. Windows recognizes that you are double-clicking something when the height and width of the response area is known. It will process two mouse clicks as a double-click when maximum allowed distance between each click is specified.
Registry Entry Details:
Registry Entry 1 :
[HKEY_CURRENT_USER\Control Panel\Mouse]
Value Name :
DoubleClickWidth
Data Type :
REG_SZ (String Value)
Size in Pixels (like '400')
Can I see what happens behind the Windows (Dell, in that case) boot logo?
Since something(TM) happened with my laptop (Dell Latitude E6440) yesterday (I suspect a Windows Update, but who knows), my Windows 10 Pro installation (17134.1, if that matters) does not boot any longer. Basically, during bootup I saw only a Dell logo indefinitely, with nothing else happening beside some initial hard disk activity.
First, I suspected the Windows Boot Manager was broken. So I have recreated the EFI partition and configured bcdedit to always show the boot menu. Now, the Dell logo disappears at one point and I can see the boot menu entries etc. I configured just fine. So I believe I can see everything around the boot manager itself is working.
However, when I select my "Windows 10 Pro" in the boot menu and press enter, the Dell logo appears again, effectively hiding everything that may be happening. The disk is active for a second or two, until the system stops as before. I have activated bootlog
for this boot menu entry, and I have also tried using the F8 menu to activate logging - but %WINDIR%\Ntbtlog.txt
is simply not written. So the Windows boot process seems to stop before it ever reaches this point
Can I debug what happens behind the Dell logo? Can I turn it off somehow?
I also remember that earlier Windows version has a step-by-step (driver-by-driver) mode, where you have to confirm every single step of the boot process. Is this still around?
routing - VMWare Workstation: How to access the virtual disk from the host system?
I would like to access the disk of a VM from host or even better from LAN. The VM runs a Windows XP. The easiest way would be an access to the c$ share.
Peace,
Ice
Update: Upon the several answers i want to refine my question: Host OS is Linux (Ubuntu). To 'see' the windows partition (c$) inside the vm a want to use the smb protocoll. How (\computername\c$ or ip-adress\c$) works the access?
Update 2: The target of this question is: How to route the smb-protocoll on a linux-box?
Answer
If you want to share the C$ drive to a LAN, then it doesn't matter whether you're using a physical server or a VM -- just use the normal Windows [In]Security model to share the drive via CIFS.
[Edit: If you need to access a CIFS network share from Ubuntu, see the Ubuntu wiki.]
If you want the host to be able to read a VM's drive, then the answer depends upon what OS the host is running, what version of VM-hosting software the host is running, and what OS and version the VM is running AND if the VM is running.
Quoting from the vmware-mount documentation:
VMware Disk Mount is a utility for Windows and Linux hosts that allows you to mount an unused virtual disk as a separate drive or partition without needing to connect to the virtual disk from within a virtual machine. You can mount specific volumes of a virtual disk if the virtual disk is partitioned.
After you mount a virtual disk, you can read from and write to the mounted virtual disk as if it were a separate file system with its own drive letter or mount point on your computer. For example, you could scan the disk for viruses or transfer files between the host system and a powered off virtual machine. When you are finished using a mounted virtual disk, you should unmount it so the virtual machine can use its virtual disk again.
If you're not using VMware Workstation, or not using the right version of VMware or Windows or Linux, you'll need to find a different approach.
How can I VLOOKUP in multiple Excel documents?
I am trying to VLOOKUP reference data with around 400 seperate Excel files. Is it possible to do this in a quick way rather than doing it m...
-
I'm working on some .bat stuff created in a legacy application, which uses many environment variables. I need to know exactly what is e...
-
Is it possible to use the tablet style on-screen keyboard on a Windows 8 laptop PC? I've found the 'Ease of Access' version whic...
-
On my desktop there are a sea of icons and I realy like ability to hide them. I can do that if do right click on desktop and find arrange ic...