Friday, December 14, 2012

Android Virtual Device Failed to allocate memory: 8

I found the answer here:
http://stackoverflow.com/questions/7222906/failed-to-allocate-memory-8

Full error:
Failed to allocate memory: 8 This application has requested the Runtime to terminate it in an unusual way. Please contact the application's support team for more information.

fix:
Lower the amount of RAM allocated for the virtual machine.


Tuesday, December 4, 2012

Using Disk Part to fix broken USBs, unformattable!

I recently had a drive break on me.  It was a 4gb flash drive that was only showing 100mb, the drive was used as a boot drive.  The MBR was taking up most of the drive and compmgmt wouldn't let me delete partitions or format the whole drive.  Enter diskpart.
Thanks Shawn at sevenforums for these tutorials.  I have the diskpart portion here because I'm terrible using favorites, Shawn has the regular disk management listed on his site also.  Shawn, if by some chance you find this and you want me to take this down I will.

Update:
I recently went through this again because I had a disk that would show up in disk management as unallocated/not initialized.  I couldn't do anything to it through disk management.
Where it has you do list volume I changed it to list disk, this showed me the two available disks.
I then ran the following commands:

select disk # (enter the number of the disk you want to impact)
attributes disk clear readonly

This cleared any readonly attributes on the disk.  I'm not sure if this was entirely needed, I'm just writing down what I did based on stuff I found online.
I then ran the following commands:

select disk # (enter the number of the disk you want to impact)
create partition primary

This got me back to RAW and I was able to format through Disk Management.
 **Note: All hyperlinks will take you to the sevenforums tutorials, I just have the delete partition and create partition here for my own quick reference**
*****************************************************************************
original source: http://www.sevenforums.com/tutorials/2668-partition-volume-delete.html

Using Diskpart in a Elevated Command Prompt
1. Open a elevated command prompt, or a command prompt at boot.

2. In the elevated command prompt, type diskpart and press Enter. (See screenshot below)
Partition or Volume - Delete-cmd_delete_step1.jpg
3. In the elevated command prompt, type list volume and press Enter. (See screenshot below)
NOTE: This will give you a list of volume numbers to select from to delete.
Partition or Volume - Delete-cmd_delete_step2.jpg
4. In the elevated command prompt, type select volume # and press Enter. (See screenshot below)
NOTE: You would substitute # for the volume number listed that you want to delete. For example, I want to delete the listed volume 3, so I would type select volume 3 and press Enter.
Partition or Volume - Delete-cmd_delete_step3.jpg
5. In the elevated command prompt, type delete volume and press Enter. (See screenshot below)
NOTE: If it fails to delete, then use type delete volume override and press enter instead.
Partition or Volume - Delete-cmd_delete_step4.jpg
6. In the elevated command prompt, type exit and press Enter. (See screenshot below)
Partition or Volume - Delete-cmd_delete_step5.jpg
7. Close the elevated command prompt.

8. The selected partition (step 4) is now deleted and is now unallocated space on the disk.
NOTE: You can use this unallocated space to create a new partition with, or extend another partition on that same hard disk into it.
to format, follow steps 1-4 above, then

5. In the elevated command prompt, type create partition primary and press Enter. (See screenshot below)
NOTE: This will create a new blank RAW partition with selected disk (step 5) that contains the unallocated partition free space.
Partition or Volume - Create New-cmd_create_step4.jpg
6. In the elevated command prompt, type list volume and press Enter. (See screenshot below)
NOTE: Look for the volume number that has the same Size as from the Free space in step 4. For example, Volume 3.
Partition or Volume - Create New-cmd_create_step5.jpg
7. To Format the Partition or Disk as a NTFS File System
NOTE: This would be good for using with a HDD as an example.
A) In the elevated command prompt, type format fs=ntfs quick and press Enter. (See screenshot below)
NOTE: Having quick added at the end of the command will do a quick format instead of a full format on the new blank RAW partition (step 6) to make it a new partition.
Partition or Volume - Create New-cmd_create_step6.jpg
8. When it is finished formatting, type exit in the elevated command prompt and press Enter. (See screenshot below)
Partition or Volume - Create New-cmd_create_step7.jpg
9. Close the elevated command prompt.

10. The new primary partition has now been created. You can now see the new partition in Computer with a drive letter.
******************************************************************************


At this point the drive will be in the RAW format and will be accessible by Windows Computer Management.  You can format to NTFS or FAT32 if you wish and use the drive like you were before it broke.


Activating office 2010, domain controller

So this blog is going to be a bunch of generic windows stuff I figure out at work that I had a pain in the ass time finding online.  Maybe my google-fu isn't as good as yours, but this blog isn't intended for you.  Its a repository of random crap I learned, maybe a blog isn't the best for this, but I'll lose word documents.

Activating Office 2010 on domain.
This is what I have found as a solution:

1)      At the command prompt, type in cd\ to get back to a C prompt.

2)      Type in the following script (32bit OS installs):  cscript "C:\Program Files\Microsoft Office\Office14\OSPP.VBS" /act

For whatever reason I've had issues doing that path, so I cd down to the folder, one folder at a time because I'm an uber noob.
cd "program files"
cd "microsoft office"
cd office14 (since its one word you don't need quotes! success)
so you end up with
C:\Program Files\Microsoft Office\Office14>
Then you just type cscript ospp.vbs /act
Boom goes the dynamite
you'll get an output listing
SKU ID:
LICENSE NAME:
LICENSE DESCRIPTION:
Last 5 characters of installed product key:
<Product activation successful>
---------------------------------------
---------------------------------------
---Exiting---------------------------

I'm pretty sure my issue was with the quotes or not putting it into the command prompt, but I'll leave both ways on here.

Temporary profile fix

Common fix found on the net:
Problem: User logs in with a message stating Profile Service cannot be loaded. As a result sees a profile with none of his/her usual documents/settings. Please ensure that you have a way to backup crucial data before attempting this.
Solution:
1. Login to a Administrator account on the local machine.
2. Open Regedit.
3. Navigate to HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList
4. There should be a multitude of Registry keys inside the ProfileList, Look for two identical ones which are differentiated by the .bak extension (e.g. xxxxxx1234.bak & xxxxxx1234).
5. The Registry key with the .bak extension contains the user's actual profile while the one without the .bak contains the Temp profile.
6. Delete the Registry Key WITHOUT the .bak extension and rename the one with it to xxxxx1234 (without the .bak). Notice the fields on the right, there should be a value named RefCount, change the value to 0.
7. Reboot the machine.

**********
Alternative:
**********
Around number 4, occassionally there won't be a .bak key
check user folders and see a user.domain or user.1, or something that indicates a duplicate, locate this folder in the profile list and edit the registry key so it points to the correct user folder.  This all sounds like jibberish, but it'll make sense when you see it.

Getting RTL8812au passed to Virtualbox VM (Ubuntu)

There are no guarantees, I just write these notes so I can come back to them. First, get the dongle working on the host OS. After going thro...