w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
windows azure virtual machine hard disk backups
Azure attached disks, just like the OS disk, is stored as a vhd, inside a blob in Azure Storage. This is durable storage: triple-replicated within the data center, and optionally geo-replicated to a neighboring data center. That said: If you delete something, it's instantly deleted. No going back. So... then the question is, how to deal with backups from an app-level perspective. To that end: You can make snapshots of the blob storing the vhd. A snapshot is basically a linked list of all the pages in use. In the event you make changes, then you start incurring additional storage, as additional page blobs are allocated. The neat thing is: you can take a snapshot, then in the future, copy the snapshot to its own vhd. Basically it's like rolling backups with little space used, in the event

Categories : Azure

Reading boot Sector of the hard disk
The boot sector of the disk contains not ASCII data, but code. With high probability, one of the first bytes will be NULL and remaining possibly not printable codes (such as CR, LF, etc.). Trying to print the buffer by INT 10h, which prints ascii codes, and ending on 0 will result probably with nothing displayed at all. You should convert every byte of the buffer to hexadecimal string and then print these strings to the display. This way you will get simple hex dump of the boot sector.

Categories : Assembly

RoboCopy , Virtual Hard Disk, or other?
I got the answer from a different thread. Basically, we are creating a Microsoft VHD (virtual Hard Disk) and filling in the files with RoboCopy and shipping the VHD. See: Unzip too slow for transfer of many files

Categories : Apache

I want to use powershell to map a network hard disk on a remote machine
PSExec is not short for "PowerShell exec", it's "process exec". You cannot execute an PowerShell cmdlet directly from it. To use PSExec to execute a PowerShell command remotely, you must do the following (untested, as I don't have psexec): psexec \func2_web1 powershell.exe -command -nologo "New-PSDrive -Name x -PSProvider FileSystem -Root \argentodrops -Persist" Or, if you want to go the remoting route from within your local PowerShell session: invoke-command -computername func2_web1 -scriptblock {New-PSDrive -Name x -PSProvider FileSystem -Root \argentodrops -Persist} With the latter, you may have "double-hop" issues that need to be resolved via CredSSP.

Categories : Powershell

How to get the total size of hard disk of Windows machine?
Look at GetDiskFreeSpaceEx(), which has an lpTotalNumberOfBytes output parameter. It is subject to per-user disk quotas, though. If you need the raw byte size of the physical disk, use CreateFile() to open a handle to the desired disk and then use DeviceIoControl(), specifying the IOCTL_DISK_GET_LENGTH_INFO control code, to get the disk's total byte size.

Categories : Windows

Azure Virtual Machine low disk space
You cannot increase your os disk size. Not sure when you created your Virtual Machine. I know that a long time ago the size was set at (I believe) 30GB, and now the os disks should be around 127GB. You may want to check what size the OS disk is. I'm not sure what chewed up your OS disk space except maybe some type of temporary os storage.

Categories : Azure

With PowerShell, is there a way to make an external hard disk attached to host available to VM?
I don't use Win8, so this is entirely untested. Judging from the description of Add-VMHardDiskDrive something like this might work, though: $usbdisk = gwmi Win32_DiskDrive | ? { $_.PNPDeviceID -like 'USBSTOR*' } Add-VMHardDiskDrive -VMName MyWin7PC -ControllerType IDE -ControllerNumber 0 ` -ControllerLocation 1 -DiskNumber $usbdisk.Index

Categories : Powershell

How to remove file permissions on linux from an external hard drive?
To make the partition accessible under Linux run: sudo chmod -R 777 /media/<drive-name>/ this should make the mac drive accessible for you. Changing ownership would do about the same, but you need not worry about it.

Categories : Linux

Creating Linux Virtual Machine in Azure from Image in Powershell
Apparently not. However, you could copy the image from storage account X to storage account Y before you create the new VM. It would only add a few more lines to your script. Here is an example: http://michaelwasham.com/windows-azure-powershell-reference-guide/copying-vhds-blobs-between-storage-accounts/

Categories : Powershell

Is it possible to address localhost from linux ubuntu to a virtualbox virtual machine
In the default network configuration (NAT) for VirtualBox you can accesss the host machine with the IP 10.0.2.2, so in the browser you would use that instead of localhost. (I can't find this in the official documentation though?)

Categories : Linux

How to solve could not create the virtual machine error of Java Virtual Machine Launcher?
Edit your Catlina.bat so that your -Xmx settings are less than your physical memory See Tomcat 7: How to set initial heap size correctly?

Categories : Java

Upload file from my virtual machine to another virtual machine using hadoop hdfs
You might find webHDFS REST API useful. I have tried it to write content from my local FS to the HDFS and it works fine. But being REST based it should work fine from local FS of a remote machine as well, provided both machines are connected.

Categories : Hadoop

Java Virtual Machine newbie Confusion: When is the virtual machine invoked while compiling java
Yes, the .class file is JVM bytecode. The JVM (invoked by java foo for foo.class) interprets (some JVMs JIT the bytecode into native machine code at runtime) the bytecode.

Categories : Java

Installation of MSI File on remote machine from local machine
You're running a remote MSI on the local host. To install the remote executable on a remote host, you could use WMI: host = "<IP ADDR>" setup = "msiexec /a ""C:MySetup<FILENAME>"" /quiet ..." Set wmi = GetObject("winmgmts://" & host & "/root/cimv2") rc = wmi.Get("Win32_Process").Create(setup, , , pid) If rc = 0 Then WScript.Echo "Setup started with PID " & pid & "." Else WScript.Echo "Starting setup failed. (" & rc & ")" End If The above will start the process asynchronously (i.e. Create returns immediately). If you need to wait for the remote process to complete, you'll have to monitor it like this: Do WScript.Sleep 100 Set p = wmi.ExecQuery("SELECT * FROM Win32_Process WHERE ProcessID=" & pid) Loop Until p.Count = 0 There may be s

Categories : Vbscript

host webapp in my machine trough virtual machine
Yes to both questions, if your browser machine can hit the port the server machine is serving the app on. On WAN, you would need to make sure your router didn't block requests to the server's port, and the same for any modem/firewall that connects you to the internet at large. Also, if your public ip is not static, it may change.

Categories : Iis

should I let mongodb make use of the new hard disk in this way?
Unfortunately this one will not be that straightforward. Even if you succeed with the mounting it will not move the files at all. What you can do is to mount the disk elsewhere (mkdir /var/lib/mongodb1, mount /dev/sda3 /var/lib/mongodb1) stop mongo copy the files from /var/lib/mongodb to /var/lib/mongodb1 (only helps if the new disk is bigger) reconfigure mongo to use as db dir the new directory or swap the names with mv commands start mongo if everything went fine, mongo started and so on,(check it first!!!) you can delete the old data. If you have a disk which is the same size so with moving the data you will run into the same problem, if you need larger space then a single disk you should play around with RAID and/or LVM and more disks.

Categories : Mongodb

How to get Windows key from disk that cannot boot?
Just for anyone having the same problem, I found this program http://www.nirsoft.net/utils/product_cd_key_viewer.html , that can find the keys also for external drives, choosing as source the WindowsSystem32configSOFTWARE file.

Categories : Misc

How can i add some bat files to my project so i will not need them anymore on the hard disk?
// create the dxdiag.bat file using (StreamWriter sw = new StreamWriter("dxdiag.bat")) { sw.WriteLine("........."); // ...... } Process proc = new Process(); proc.EnableRaisingEvents = true; proc.StartInfo.UseShellExecute = false; proc.StartInfo.FileName = "dxdiag.bat"; proc.StartInfo.CreateNoWindow = true; proc.Start(); proc.WaitForExit(); proc.Close(); //delete the file File.Delete("dxdiag.bat");

Categories : C#

which widget to use to show hard disk sectors as hexadecimal?
How do they achieve this in a single scroll area It is not a "single scroll area" containing the entire disk. It is a scrollbar and dynamically generated content for whatever disk content you are showing at the time. Simply calculate the position based on the scroll location (unless your screen is 10000's of pixels tall, however, you will not be able to place the cursor EXACTLY on the disk sector you want). also provide the undo functionality in that.... Undo functionality, I expect (I haven't looked at the code) is done by holding "address changed, old value" in some sort of container. Pretty much the same way you'd do undo information for any other large dataset. which widget should be used to display such a huge amount of data.???? One which shows text and allows yo

Categories : C++

Serving Static content from local hard disk in jboss as 7
As of my knowledge, we dont have an option to access static files on the hard disk through JBOSS AS 7.1. The solution I have tried was , I have created a dummy web application and I have been storing the files into the dummy web application. Once the files are stored over there, they are accessed with URL pointing to newly created dummy web application. Though this is not the correct way for this kind of access, I find no other way for this. Pl. let me know if any other ideal way exists... Thanks....

Categories : Java

Why when loading html file from the hard disk through WebBrowser not everything is shown?
When you download the page, you download the source code of that page. However, when your browser downloads the page, there are a lot of stuff downloaded along with the HTML. For instance, there are JavaScript files, CSS files (for styling) and more. Even if you download them as well, you may need to modify your HTML to link those files to the HTML with a relative or absolute path (depending on your needs). In other words, the web page is not shown as you expect because the attachments are not downloaded and linked to the HTML. Update When you set the source of the document, the attached documents (css, js, etc.) relative to the HTML are not found and therefore not used in the web page. For instance: <link rel="stylesheet" type="text/css" href="//cdn.sstatic.net/stackoverflow/all.cs

Categories : C#

Write files into randomly non-contiguous hard disk positions
I think that the only way to do this is using some low-level OS commands No... RandomAccessFile has .seek(): final RandomAccessFile f = new RandomAccessFile(someFile, "rw"); f.seek(someRandomLong); f.write(...); Now, it is of course up to you to ensure that writes don't collide with one another. Another solution is to map the file in memory and set the buffer's position to some random position before writing.

Categories : Java

How can I resume connection between SQL Server and physical files after hard disk disabling?
Lets start saying that you are in a very bad shape and you should check your physical server ASAP. IMO, the best thing to do is backup the files as-is just in case you can't do anything else then one of the following options restart SQL Server service delete the broken database restore restore back ups to the latest transaction point If the above is impossible. restart SQL Server service hope that things will work

Categories : Dotnet

Read Streaming Excel file which is not saving content to hard disk
There is approch you can follow: open temp.xls with readonly flag with standard way: Workbooks.Open Method Perform your traitement on data. Peraphs copying content to another Workbook. detect changes on temp.xls using FileSystemWatcher Class and reopen it as 1st point Another thing can be useful is to detect end of process from abc.exe. Maybe it is only by detect non-existance of temp.xls or non-existance of abc.exe in table of process (via ManagementEventWatcher Class). Anyway at this point you should sniff everything passing thru temp.xls.

Categories : C#

getting size of multiple files located inside the hard disk using python
if item < 1000: size = str (item) + 'K' if item > 1000: #this will never execute #since you have already asserted that item < 1000

Categories : Python

How to copy only file permissions and user:group from one machine and apply them on another machine in linux?
How about this? #!/bin/bash user="user" host="remote_host" while read file do permission=$(stat -c %a $file) # retrieve permission owner=$(stat -c %U $file) # retrieve owner group=$(stat -c %G $file) # retrieve group # just for debugging echo "$file@local: p = $permission, o = $owner, g = $group" # copy the permission ssh $user@$host "chmod $permission $file" < /dev/null # copy both owner and group ssh $user@$host "chown $owner:$group $file" < /dev/null done < list.txt I am assuming that the list of the files is saved in "list.txt". Moreover you should set the variables "user" and "host" accordingly to your setup. I would suggest to configure ssh to have "automatic login". Otherwise you should insert the password twice per loop. Here

Categories : Shell

To find duplicate files on a hard disk by technique other than calculating hash on each file
You may want to use multiple levels of comparisons, with the fast ones coming first to avoid running the slower ones more than necessary. Suggestions: Compare the file lengths. Then compare the first 1K bytes of the files. Then compare the last 1K bytes of the files. (First and last parts of a file are more likely to contain signatures, internal checksums, modfication data, etc, that will change.) Compare the CRC32 checksums of the file. Use CRC rather than a cryptographic hash, unless you have security measures to be concerned about. CRC will be much faster.

Categories : File

Provide uploading files, write the file on hard disk, get full path (string) to add in database CakePHP
While this may not give you a direct solution in CakePHP, you had asked for some ideas. I've outlines some pros and cons of storing a file on the filesystem (along with some other approaches) in this post. Hope that helps...

Categories : PHP

How to fix TPM in Redhat Linux? RedHat Linux hang on first time to boot after installing
After all my search I found out that in Redhat 6 there is a problem tboot and best way to fix it is to remove tboot package (it is located in System Base>Base>tboot.6) For more info about tboot you can check these links: enter link description here

Categories : Linux

Unmount my external hard drive in bash
Searching for "Unmount Hard Drive Terminal" yields http://ubuntuforums.org/showthread.php?t=842698 as the first result. >.> russlar provides a solution: open terminal, and run df -h. this will tell you all the hard drives mounted. then, run sudo umount /dev/something, where somethign is the name of the hard drive that you want to unmount. Nothing wrong with asking, but when a solution is on the first Google result, it's a little... odd.

Categories : Misc

Installation and emulation of virtual USB Device
I used the USB/IP project to emulate USB devices in Python. Maybe it can help you to create your virtual USB devices: http://breaking-the-system.blogspot.com/2014/08/emulating-usb-devices-in-python-with-no.html

Categories : Windows

Mac: Updated HOME environment variable in /etc/launchd.conf and now machine wont boot
I'll give you two options, but first a warning: both of these involve using the command line to undo the damage, and if you do it wrong there's a possibility you'll make it even worse. A backup would've been a good idea, but it's a little late for that (well, actually, there are still ways to do it, but they also involve a risk of getting it wrong...). So whatever your do, be careful. Option 1: use single-user mode (Command-S at startup). This will leave you running as root, which means you are not subject to normal file permissions; after remounting the startup disk for write access (mount -uw /) you should not get permissions errors. You said this didn't work; the most likely thing is that you mistyped the command (I see this happen a lot -- people either leave out the "/", or the space

Categories : Osx

Export rmi on virtual machine
Change the networking mode of the virtual machine to "bridged" so it will be in the same network as the host. Java RMI was not designed to work with NAT, so you'll have trouble with the default networking mode. After that, change registryHost to the IP address of the VM, 127.0.0.1 can only be accessed from within the machine. (There are other ways to make this work but this is the easiest to explain)

Categories : Java

Virtual Vending Machine
There are a lot of different ways to do it. Here's one: if (SELECTION == MILK_CHOCOLATE) { System.out.println("Please enjoy your milk chocolate."); } By the way, the convention is to use ALL_UPPERCASE for constants, that is, values that will stay the same throughout the life of your program. So while MILK_CHOCOLATE is a constant, the user's selection isn't. You should name that variable selection instead. The Java compiler doesn't care, but the code will be easier for other programmers to read.

Categories : Java

Cannot access ubuntu server from other machines other than the machine which is hosting the virtual machine which is my ubuntu server
First of all make sure in the setting of the virtual machine that it is in Bridged Adaptor type connectivity. Give a static ip to the virtual machine using sudo ifconfig eth0 10.0.0.100 netmask 255.255.255.0 the above is an example. You got what I mean. 3.Third, Try pinging the virtual machine with the base machine running the vbox to make sure they are connected. ping ipaddress-basemachine 4 . Now if everything is working fine from there then connect with this virtual machine with other base machine using Remote Desktop Viewer or any other similar application. Specify, the ip-address of the vbox and username, password. It will be able to connect with it now. 5 . If it still is not able to then try to check the firewall rules on both the virtual box machine and the base machine

Categories : Linux

Preparing an Installation and Installing on client machine
You should probably put your code in a repository - probably git via GitHub is best. If the setup is going to be different then perhaps gitignore the database.yml but include a .sample of it. Then to install on someone's machine just checkout the repo bundle install and run the relevant rake tasks (db:setup probably). Updates can then be applied by pulling from the repo. Other than that zip it up and unzip on there machine making sure to install everything required.

Categories : Ruby On Rails

java virtual machine Crashing
Look closely at the error message. It says there is not enough memory for the test JVM's heap. Try releasing some memory (shutdown Eclipse) and/or run the tests with a lower heap / perm gen size (surefire setting).

Categories : Java

installing android x86 in a virtual machine
check here www.bitdirect.nl/?p=128 I followed this with a few little tweaks here and there and it worked perfectly. only downside is transferring data outside of the android os is a pain.

Categories : Misc

OpenGL problems in virtual machine
If you are a noob then I don't think that starting with MESA running on any kind of VM is a good idea.MESA setup is pretty complex in general.Also MESA OpenGL is outdated.It supports up to 3.2 version atm.If you want to get started with OpenGL the right and clean way you should better setup context with libs like GLUT or GLFW and load GL extension with GLEW(there are more). Also, there are many tutorials on the net on how to get started with OpenGL.One of the best is probably this. And don't use VM,it slows down performance considerably. UPDATE: As it was correctly pointed out here by Datenwolf, MESA implementation is not "outdated" but rather lags after the latest OpenGL specification which is currently 4.4

Categories : C++

Can you replicate an azure virtual machine?
Yes, you can use the capture capability to create a base image that you can then use to deploy other machines from. Take a look at these instructions: http://azure.microsoft.com/en-us/documentation/articles/virtual-machines-capture-image-windows-server/. This assumes you are referring to a Windows Server machine. Also, it assumes that a sysprep won't affect the software you have installed. If a sysprep will cause a problem them you also might be able to take a copy of the underlying VHD and spin up a different machine from the copy. Both methods are explained in this article here: http://community.adxstudio.com/blogs/shan/2012-06-28-cloning-windows-azure-virtual-machines/

Categories : Azure



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.