Free Up Space On Your SSD With Windows 7 and 8 Installed By Turning Of Hibernate

If you computer is real short on SSD space and your Windows OS is installed on it, and especially if you have large amounts of RAM on your system, you can free up SSD space by turning Windows Hibernate off.

When your computer hibernates it stores a full image of your memory in the file hiberfil.sys.  This file is located normally in the top of your drive along with other system files like pagefile..sys, swapfile.sys (these files are needed don’t delete them).  All of these files are hidden by default from the user until you turn on “show hidden files” in the Windows file manager.

Yes there are other ways to turn off hibernate (thru power saving options GUI –  deleting the hiberfil.sys file is not one of them – it will just come back) but,  the easiest way to turn off hibernate in my mind is:

  • turn off hibernate is to run a DOS command window as Administrator
  • issue the command “powercfg.exe /hibernate off

Immediately C:\hiberfil.sys is removed – whether you could see it or not and space is freed up on your OS disk drive – works with any kind of drive not just SSDs.

Again, this is really beneficial if you have lots of RAM and are short on disk space.

I don’t want to use hibernate and over the long run it has caused more problems that it resolved.  Typically it takes a long time to restart from hibernate and frankly I’d rather have the space.

Hope this helps, Mike

Advertisements

Charter Internet Access Problem From My Router – MAC Address Clone might be the solution

My Internet accessed stopped working today – my internet service has been provided by a company named “Charter Cable” that services several state in the US.  After troubleshooting (rebooting routers, and cable modem, and direct connecting the cable modem to my laptop) I narrowed it down to my personal Linksys router, a direct connect from Charter’s cable modem (happens to be a Motorola SB6121) to my laptop worked – I did have internet access when cutting the modem out of the loop.  I have a couple of Linksys routers, the one that was working stopped working, and another older Linksys ES4200 that had always worked at another location until I stopped using it.

I swapped out the non-working modem, with the older ES4200 that I believed was also functional, STILL NO INTERNET ACCESS.  The router could not see the cable modem.  Neither of them could.

Motorola SB6121 has an internal NAT-ed IP address of 192.168.100.1 when I direct connected from the modem to my laptop, I could see and manually configure the cable modem if I wanted – I didn’t want to.  And of course, when I cut the routers out of the deal, I had internet connectivity to my laptop direct.  I COULD CRUISE THE INTERNET.

Spoke with Charter twice and of course they didn’t want to get into troubleshooting my router.  Last question I asked was: do I need to do a “MAC Address Clone” on my router – from the computer that worked when directly connected (I had plugged it back into the router while troubleshooting).  The nice lady said “No” you don’t need to do that and we hung up after – she told me I could pay them to come out and for $99 setup fee and $3 per month, they would provide a router, I passed on that option “for now”.

I immediately did a “MAC Address Clone” and my router started working… all internet access to all of my computers, tablets, and smartphones has been returned through my router at least one of them.  By the way, then I did this on both routers just to make sure there was not a hardware failure or something else on either router and voila, they both work now.

How did the original model start failing after 8 months of no issues??? don’t know.  I know cloning the mac address was required to get either Linksys modem working.

Again, the “MAC Address Clone” is a function provided by your router – normally supplied by you.  Different routers put the function under different menus… so I can’t help you there but, I would say almost all routers provide the function.  It will likely be under internet connectivity or network connectivity.  One of my Linksys actually had a MAC Address clone tab.  The other had the option under “Internet Connectivity”.

After taking a couple hours figuring out and ignoring Charter’s miss-information, I googled and found that Charter is doing this to lots of people… I have no problem with them not troubleshooting my router.  But telling me the solution to a problem is NOT a solution, is not good.  Hear me Charter Technical Support?

Hope this helps, Mike

Permanently Disable Windows 8.1 help tips or just make one go away

Win 8.1 help tips popup if Microsoft thinks you might need them and won’t – yes will not – go away unless you follow the help tips directions, whether you want to invoke that function or not.

Here’s the URL to a Microsoft article to permanently disable all popup Win 8.1 help tips, if they are annoying you or you are on a non-touch display where the tips have very little value.

http://answers.microsoft.com/en-us/windows/forum/windows8_1-windows_install/help-tips-pop-ups-how-can-i-disable-them/044dc900-ef8c-4821-91d2-73e96dbf4387

Additionally, if you just want to make one disappear – and not permanently disable all help tips – follow the help tips instruction (you can do this with touch or a mouse) and then it will go away and that particular tip should not come back anytime soon.  Microsoft should just put an X on it to close these annoying little pieces of stuff… duh.

Hope this helps, Mike

Apex Listener 2 Displays Blank Page – is a bug fixed by patch # 16760897

I was attempting to implement the standalone version of Oracle Apex Listener 2 – and getting blank pages.

Prior to this I was successfully using EPG ( embedded PL/SQL gatway) to access Apex but changed to take advantage of PDF printing in APEX Listener 2.

Problem was page kept coming up blank – and all the forums, google, metalink etc. tried to tell me it was a problem with not pointing to the images.

Well I knew I was pointing to images correctly.  Here is the command to explicitly start Apex Listener 2 and point at an images directory in standalone mode:

java -jar apex.war standalone –apex-images D:\app\Apex422Setup\apex\images

After a couple days of googling, and using metalink (this fix was not in metalink …) I finally I found a forum that got to the source of the problem (http://localhost:8080/apex displaying a blank page) – an Oracle / Apex 4.2.2.0.11 specific bug.

Bug # is 16760897.  Fix is in patch # p16760897_422_Generic.zip.  The problem probably rears it’s ugly head no matter how you deploy the listener, standalone, glassfish, and Weblogic… I believe.

Also you can get Apex 4.2.2 to display the login page without the patch by using the following form of the url:

http://localhost:8080/apex/f?p=4550:1

Once you hit this URL the problem goes away until the cache is cleared – only a temporary fix. Or you apply the patch.

SQL> select * from apex_release;

VERSION_NO
——————————————————————————–
API_COMPATIBILITY
——————————————————————————–
PATCH_APPLIED
——————————————————————————–
4.2.2.00.11

Hope this helps, Mike

.netrc and a here document to automate and script FTP

Using a .netrc file combined with a “Here Document” for ftp scripting can simplify ftp scripting by automating the login and setting up macros – that can be run from a scripted ftp session

Here is an example .netrc file from something I did recently.  Note do a “chmod 600 .netrc” after you have created the file to give it the correct file permissions to be used.

  • the first line specifies a machine name that can be automatically logged into

.netrc

machine myhostname login remoteusername password remotepassword

Now here is the “Here Document” contained in the bash script testf.bash that does most of the work.

testf.bash

dtstr=$(date +%Y_%m_%d); export dtstr
cd /u01/app/oracle/fast_recovery_area/PROD/backupset/$dtstr
echo “date is: “$dtstr
ftp -v rh2 <<EOFMark
ls
mkdir $dtstr
cd $dtstr
prompt
mput *
quit
EOFMark

SQL Developer on Mac OS Creates large log file on startup

After installing SQL Developer 3.2 on Mac OS 10.8.2 my disk space started running out. And kept running out. SQL Developer was constantly appending to a log file in /tmp

I traced the problem to the startup .sh script for sql developer.

/Applications/SQLDeveloper.app/Contents/MacOS/sqldeveloper.sh
bash ./sqldeveloper >/tmp/sqldeveloper-startup-`uuidgen`.log

I stopped sql developer from creating the  log file and that fixed the problem, plus, sqldeveloper starts up faster, probably runs faster etc. So, if you don’t want this logging going on… just change the command to:

bash ./sqldeveloper

Not sure how this logging got put in place (maybe it was an install gone wrong?) and got out of control… but I learned how to stop it.

Oracle Enterprise Manager Not Functional From MS Internet Explorer V7 & 8 After MS Windows Patch KB2661254

Sorry I just got around to posting this fix for at Microsoft security patch that came out in October 2012 for MS Explorer versions 7 & 8 at least.  It’s a patch that forces 512 encryption when encryption is used.  So those apps that don’t support 512 byte encryption like Oracle Enterprise Manager (OEM) 11.1 BREAK… unless without massive additional patching to OEM ugh…

Here is one relativesly easy fix (in my mind – of course you could just use Chrome – the MS patch doesn’t break that) and then the note that led me to the fix for our Oracle Enterprise Manager problem (not able to get to the URL – browser blocks it because the key is only 512 bits).

Test OEM from MS IE 8 first, if its not working, and you just applied the patch, before you make these changes to assure you need the changes to your registry.

On the client running the IE browser

You may want to backup your registry before you do this…

  • ·         Run regedit.exe
  • ·         You may want to backup your registry…
  • ·         Navigate to: HKEY_LOCAL_MACHINE\Software\Microsoft\Cryptography\OID\EncodingType 0\CertDLLCreateCertificateChainEngine\Config
  • ·         Add a new DWORD for: MinRsaPubKeyBitLength  Value Decimal 512
  • ·         Add a new DWORD for: EnableWeakSignatureFlags Value Decimal 2
  • ·         Stop all running version of IE

http://support.microsoft.com/kb/2661254 explains what needs to be done but, it is buried about 10 pages down in the note…  hint, search for MinRsaPubKeyBitLength.

What you will see is Microsoft provides a work around with 4 registry entries of which you only really need 2 of the 4.

Hope this helps, Mike

Adding / Configuring an Oracle Standby To Oracle Enterprise Manager

After adding a Data Guard Standby database node to our list of managed systems, the node showed a red arrow – and that a database shutdown or recovery is in process.

For regular database nodes you usually use the Oracle User DBSNMP – Oracle user account for agent monitoring and connect as a “NORMAL” Oracle user.

A standby database is in recovery, Oracle’s documentation does not explicitly state this (at least anywhere I can find), to monitor a standby database properly the configuration in OEM – for a standby node – should be to Oracle’s SYS user as SYSDBA type connect, NOT a NORMAL type connection.

This makes sense when you think about it, a standby database is in “managed recovery” and the only way to connect to an instance in that state is as SYS AS SYSDBA.

I initially set this up with the standard DBSNMP user and the instance status always showed  RED / and displayed an error.  To make matters worse, the username field is not editable until you change the connect type to SYSDBA (not intuitive at all) – only then can you change the username to SYS… so much for that great OEM documentation.  Even metalink.oracle.com / Oracle Support doesn’t have anything on this “feature”.

So now all of our OEM standby database arrows are green… green is good…

Hope this helps, Mike

Installing And Configuring Oracle APEX Listener With Weblogic 10.3

August 12th, 2012

Well we decided to host our production DW Apex applications using the Apex Listener with Weblogic.

I got the task of doing this.  The Apex Listener option is relatively new to Apex, older versions use OHS / Apache.  Not only am I new to this listener architecture but I’m also fairly new to Weblogic, although I have admin’d Oracle older application server technologies for years.

I’ve setup APEX with the EPG (embedded PL/SQL gateway) recently, which was relatively painless.  I’ve also setup older versions of APEX with OHS / Apache on the same host as the database, slightly more complex but not too time consuming either.  All total, there are 3 different options for configuration of a listener / web server for APEX.

For any of these Oracle links you may have to have an OTN account/pw – easy to setup goto to otn.oracle.com if you do not have one.

Apex Installation Guide is here:

http://docs.oracle.com/cd/E23903_01/doc/doc.41/e21673/toc.htm

Apex Listener Installation Guide is here:

http://www.oracle.com/technetwork/developer-tools/apex-listener/overview/index.html

We chose WLS and Apex listener for it’s flexibility, scalability, security features for our DW production environment and last but not least we have an Enterprise license for WLS so it’s basically free.

It appears the Apex Listener is written in Java and should be loaded as a servlet / service in as a Weblogic Application.  In our case, we are separating the application server WLS from the database they will live on two different hosts.

So I’m following along with the section of Oracle’s installation that applies to Apex Listener / WLS, and right away I’ve got questions.

The documentation states to install Apex run the following command from sqlplus;

SQL> @apexins SYSAUX SYSAUX TEMP /i/

Ok that was easy enough, until I realized that I ran it from the database node and maybe that command needed to be run from the middle tier / WLS node.  Why would I assume that?  Because of the “/i/” in the apex ins command (clearly my assumption could be wrong too).

The /i/ appears to be an image directory and I assume that it should be on the middle tier.  And Oracle’s Apex Listener installation documentation is of absolutely no help.  It does not even mention the concept of multi-tier, not to mention which host the commands should be run from if you are creating a multi-tier env.

Yes, I’m confused but, most of that confusion is about to eliminated, read on.

After posting a few basic questions related to this install on Oracle’s Apex Listener Forum, reading a bit of WLS documentation and re-reading the Apex Listener installation documentation a second time, it dawns on me that it is telling me to create an “i.war” and load that into Weblogic, and that automatically creates a WAR based directory structure for images, DUH…  So yes, the directory structure will be created on the middle tier for images in WAR format.  This is on top of installing the apex.war that comes with the Apex Listener download…

The i.war file is created with a command like:

First you have to cd into the images directory where you unwound the apex.zip file… Apex zip, not Apex Listener zip.  Yes, if you don’t have this zip where you are running WLS from you may have to unzip it on this host even though it was already installed from elsewhere.

This command creates a i.war file that is deployed along with the supplied a.war containing your specific image related info – the listener needs your specific install information.

cd \<apex directory\images

jar –cvf0 <temp directory>\i.war –C <apex directory>\images .

Everybody says, "watch out for that last period, it is required".  So, now you know too, it is required.

The “jar” command above should be run from the node that contains your apex installation.

Getting that i.war file loaded into WLS correctly so that it plays nicely with my previous Apex install command: “@apexins SYSAUX SYSAUX TEMP /i/” command is now the immediate challenge.

More on my trials and tribulations later…

August 16th 2012

Turns out 90% of this effort was climbing the WebLogic Admin learning curve.

More specifically Weblogic tasks in order of execution included:

  • Weblogic installation, whether or not they are 64 bit and or 32
  • Which version of Weblogic shall we use (yes I played with 10.3.3, 10.3.6 and 12c and so far have settled on 12c)
  • Creating Weblogic domains
  • Within a domain creating, configuring, starting and stopping Admin Servers / Consoles, Managed Servers
  • Within a server deploying applications apex.war and i.war
  • Configuring SSL
  • Auto start of servers

Oracle’s WebLogic 12c install docs are here – while I’m sure 12c has many new features administration seems to be basically the same as 10.3.x:

http://docs.oracle.com/cd/E24329_01/doc.1211/e24492/install_screens.htm

Once I got all that down – and it’s not all done yet but, I do have a working Weblogic domain, server and apex listener application deployed within that server.  Still have some work to do.

All in all, a few days worth of reading Weblogic blogs, Oracle’s Weblogic documentation and then back to the original Apex Listener install documentation and it’ about there.  At least I’ve got the concepts down and a basic working installation.

If you are doing a 64 bit install of WebLogic, pick the generic jar and download a 64 bit JDK + JRE, separately.  It seems JRocket (an optimized version of Java now owned by Oracle) is frequently used with WebLogic.

Oracle’s Apex Listener Installation documentation (link above) is spot on, followed it to the T and works well (several host installs).  If you already know Weblogic well, it’s a piece of cake…

Eventually I setup both the Apex Listener (deployed in WebLogic 12c) and the Embedded PL/SQL Gateway (EPG), both supporting the same DB/Apex instance, simultaneously (yes this appears to work without issue).  A link to “Hendry’s Oracle DBA Stuff” below helped me remember how to setup the EPG (thank you Hendry)…

http://hendrydasan.com/2010/07/01/install-and-configure-apex-4-0-in-oracle-database-11gr2/