3DS Will Not Power on even though it is charged — how to fix it (maybe)

My 3DS wouldn’t power on this morning. I hadn’t used it for a week. I guess the battery was as flat as a pancake. After charging the 3DS for an hour it still wouldn’t power on (it was still plugged into the mains and charging as far as I could tell).

Hmm. That’s a bit weird I thought. In a fit of desperation/pique I removed the game card (Mario Kart 7) and I removed the SD Card too. I immediately tried to power on the 3DS and bingo it came on first time. I powered it down again, put the SD card and game card back in and bingo, it powered up again.

Phew.

 

Seamus

The Bears Breeches

 

 

Fix Database Won’t start due to invalid parameter in spfile.

Hmmm. Database Won’t start due to invalid parameter in spfile.. hmm..

This is a quote from appsdba.comWhen using an SPFILE it is possible to get into the situation where the database won’t start due to an invalid parameter, and since the database won’t start it is not possible to fix the SPFILE.

I got into this situation this morning. Its very very frustrating but relatively straightforward to fix. Here goes.

Step 0: Check for a pfile equivalent of your spfile! If it exists then start the database using startup pfile=/path/to/pfile and issue a create spfile from pfile when the database starts and then restart your database. Bingo. Amend your spfile parameters at your leisure. If you haven’t got a pfile then read on..

Step 1: find your spfile. If you don’t know where this is you’re goose is already cooked. It usually lives in $ORACLE_HOME/dbs and is called spfile<ORACLE_SID>.ora though yours may have a different name. In my case the ORACLE_SID is TEST so my spfile is called spfileTEST.ora. 

Step 2: Back up your spfile (and pfiles too).

Step 3: Open a command prompt, navigate to the directory containing your spfile and type strings spfile_name > $ORACLE_HOME/dbs/temp_pfile.ora (this creates a pfile not an spfile!!). If the spfile file is in $ORACLE_HOME/dbs then rename the spfile to something you’ll remember…  IF the spfile is stored within ASM then login as the ASM owner, start asmcmd and use the cp command to copy the file to a directory your database/instance owner can read and run strings /path/to/spfile/spfile_name > $ORACLE_HOME/dbs/temp_pfile.ora.

Step 4: open temp_pfile.ora with a text editor and check its parameters. Tidy up incomplete entries and amend offending entries where appropriate. (I’d accidentally reduced one of the memory parameters from 24G to 2G preventing the instance from starting up).

Step 5: try starting up the database.. startup pfile=/path/to/file/temp_pfile.ora should do the trick. If the instance starts shut it down immediately (shutdown immediate should do the trick). If the instance doesn’t start then check your parameters and try again!

Step 6: rename temp_pfile.ora to init<ORACLE_SID>.ora. Mine is called initTEST.ora.

Step 7: startup the database again. once its started type create spfile from pfile and press enter.

Step 8: Restart the database. Your database should now start up but this time its using the newly created spfile.

Step 9: Take applause from your colleagues and count your lucky stars.

 

This document was typed rather hastily on a train on my way home. If you spot a mistake please let me know.

 

Enjoy,

Seamus

 

 

TSM client tuning (Tune your TSM Client)

If you’re TSM backups are taking an age to complete and you want to try to do something about this then read on. It is possible to Tune your TSM client. This little piece won’t go into the ins and outs of tuning the TSM client. Rather, I’ll give the before tuning stats, the post tuning stats and the changes to the dsm.sys file I made to do this. BTW, these optimizations are for TSM Client 6.2.1.0 on Redhat Enterprise Linux 5.8 and i’m backing up a compressed RMAN backup of an Oracle database that is about 100GB in size.

The ‘before’ position.

SErvername        TSM_SERVER1
COMMMethod        TCPip
TCPPort           1500
TCPServeraddress  192.168.1.1
Passwordaccess    generate
TCPNodelay        YES
TCPBuffsize       32
TCPWindowsize     64
TXNByteLimit      25600
Nodename          NODE1
InclExcl          /opt/tivoli/tsm/client/ba/bin/inclexcl.list

 

This was pretty much the default dsm.sys bar the node name and server name. The summary from dsmc incr was..

Total number of objects inspected: 3,600,655
Total number of objects backed up:    6,243
Total number of objects updated:          1
Total number of objects rebound:          0
Total number of objects deleted:          0
Total number of objects expired:         85
Total number of objects failed:           3
Total number of bytes inspected:     374.40 GB
Total number of bytes transferred:   94.03 GB
Data transfer time:                21,723.66 sec
Network data transfer rate:        4,538.74 KB/sec
Aggregate data transfer rate:      4,113.49 KB/sec
Objects compressed by:                    0%
Total data reduction ratio:           74.89%
Elapsed processing time:           06:39:29
xx/xx/12 03:39:33 TSM incremental backup ended

 

The average elapsed processing time for my backups was about 7 hours. Thats a long time. Compare that to the ‘after’ position.

The ‘after Position’

I made a couple of changes to my dsm.sys file:

 

SErvername        TSM_SERVER1
COMMMethod        TCPip
TCPPort           1500
TCPServeraddress  192.168.1.1
Passwordaccess    generate
TCPNodelay        YES
TCPBuffsize       32
TCPWindowsize     256
TXNByteLimit      25600
Nodename          NODE1
InclExcl          /opt/tivoli/tsm/client/ba/bin/inclexcl.list
MEMORYEFFICIENTBACKUP No
RESOURceutilization 10

 

I’ve highlighted the changes with bold type. Now the dsmc incr summary looks like:

Total number of objects inspected: 3,869,826
Total number of objects backed up:    6,253
Total number of objects updated:          0
Total number of objects rebound:          0
Total number of objects deleted:          0
Total number of objects expired:        278
Total number of objects failed:          11
Total number of bytes inspected:     320.06 GB
Total number of bytes transferred:   100.27 GB
Data transfer time:                66,562.14 sec
Network data transfer rate:        1,579.60 KB/sec
Aggregate data transfer rate:      10,010.40 KB/sec
Objects compressed by:                    0%
Total data reduction ratio:           68.68%
Elapsed processing time:           02:55:03
xx/xx/12 23:55:06 TSM incremental backup ended

 

The average elapsed processing time has dropped from an average of about 7 hours to an average of about 3. Maths isn’t my strong point so I’ll leave it to someone better at maths than me to work out the time saving. For me the average Aggregate data transfer rate has risen from around 4000 KB/sec to around 10,000 KB/sec.

Please leave a comment if you found this useful. Or even better, link to me.

Regards,

Seamus.

 

Redhat Virtualization, its installation and the pesky “ERROR Host does not support any virtualization options” error message fix

If you’re setting up a Redhat server as a virtualization host running KVM and you’re following Redhat’s instructions’s as per Redhat’s  Red Hat Enterprise Linux 5 Virtualization Guide Edition 5.8 then there’s something you must do between installing the required packages (see Sections 6.3 and 6.4)…

I found that if I took an existing RHEL 5.8 installation and installed the necessary packages detailed in section 6.4 then virt-manager would fail with the error message ”ERROR Host does not support any virtualization options“. Strange as my server had virtualisation extensions enabled in the bios.

 

The answer was to reboot the server. its seemed that /dev/kvm was missing and on reboot it is  miraculously created.

After the reboot I could create VMs to my heart’s content.

 

Thought you might like to know,

Seamus

How I installed the Flash Plugin with Centos 6.3

Maybe it was a little naive of me to expect my newly-installed CentOS installation to have the Adobe Flash plugin installed by default… After a little scratching of heed It turned out to be easier to do than I thought it would be.

Here’s how I did it:

 

  • Fired up Firefox and headed over to http://get.adobe.com/flashplayer/
  • From the Select version to download drop-down box I selected .rpm for other Linux and clicked  on Download Now.
  • You’ll be prompted to save a file called something like adobe-release-x86_64-1.0-1.noarch.rpm.  I saved it in my standard download folder.
  • Start a Terminal session (I used Konsole) and, if you’re not logged in as root, type su – root and press enter.
  • Change your current directory your Downloads directory (cd Downloads and press enter).
  • type rpm -ivh adobe-release-x86_64-1.0-1.noarch.rpm and press enter.
  • It would seem this doesn’t install the flash plug-in (I could be wrong here but it happened to me…) – it sets up yum with Adobe’s repository settings… so, you need to do the following:
  • type yum list | grep flash and press enter.  You should see a line like flash-plugin.x86_64 11.2.202.236-release @adobe-linux-x86_64 if all is well.
  • Now to install the plug-in proper. Type yum install flash-plugin.x86_64 and press enter.
  • After a few seconds the plug-in will be installed.
  • [Re]Start Firefox.
  • Check the plug-in is working by heading on over to http://www.adobe.com/software/flash/about/

 

Sweet. Bit of a faff on but after this Bob really is your Uncle.

 

Seamus.

How To Change DNS Settings on your Mac

So, why woud you want to know How To Change the DNS Settings on your Mac? If you use wi-fi or even a wired connection chances are DHCP sorts out your DNS settings for you. Well, I’ve been having problems with my Mac and surprise surprise it uses DNS settings supplied by my router which in turn routes me to my ISPs DNS servers for name resolution. After a bit of testing the problem appeared to be my ISP’s Servers that were the problem and so, after rummaging around the world wide web of useful info for advice on what to do, I decided to use Google’s Public DNS Servers instead of my ISPs. Google’s Public Servers are at 8.8.8.8 and 8.8.4.4.

Here’s how I changed my settings:

 

Seamus

 

Finally, Bing is indexing this blog !

Finally, Bing is indexing this blog ! Its taken six months for itto get round to indexing all of the pages in this blog. At first I thought I was doing something wrong – I checked, double checked, tried again and nothing. So, I hate to say it, I gave up with Bing. Compare this with my experience with Google which indexed pretty much everything within a week.

All of a sudden though, Bing has indexed all of my pages and Its finally sending traffic to my site. Not a great deal though. For every thousand referrals from Google Search I’ll get two at most from Bing.

So, Should I persist with Bing? Should I have bothered in the first place? All I’ll say on the matter is it took me 10 minutes to register with Bing and set up indexing. It took around the same amount of time with Google. In terms of return on effort Google is the clear winner. Still, for 10 minutes work I’m getting a few hits from Bing. I’ll report back if the volume of traffic from Bing increases.

 

Seamus

How to import Enterprise Manager Grid Control Data into Excel and Create Attractive Looking Graphs and Charts

It is really not difficult to import performance data from your Enterprise Manager Grid Control setup and produce some very nice looking graphs from the data stored within.

Here’s one I made earlier.

Custom Oracle Enterprise Manager Graph / Report produced using Excel

A nice 3D graph of Enterprise Manager repository data demonstrating how much nicer Excel’s graphs are than Oracle OEM’s

 

Here’s how to do it:

  1. The first step is to install ODAC. You must do this because in my experience, on a Windows XP PC, Microsoft’s ODBC for Oracle driver doesn’t appear to handle Oracle’s sysdate at all well. You can download ODAC (11.2 Release 4 (11.2.0.3.0)  in my case) from Oracle’s rather swish download pages.
  2. The next thing to do is create an entry for your repository database. Make sure you edit the tnsnames.ora that is part of the ODAC installation or this won’t work.
  3. Create an ODBC data source using the tnsnames entry you created in step 2.
  4. Fire up Excel.
  5. From the menu bar select Data / Import External Data / New Database Query
  6. Select the ODBC data source you created in step 3.
  7. Enter your username and password. Username will be sysman, see your admin people if you don’t know the password.
  8. The MS Query query wizard shop pop up. Expand the the first table that appears in the Available Tables and Columns list and add the first row only to Columns in your query (for me the table is AQ$_MGMT_ADMINMSG_BUS_G and the first column is MSGID).
  9. Keep clicking next until you reach Query Wizard – Finish and you’re asked what you want to do next.
  10. Select the middle option – View Data or Edit data in Microsoft Query and click finish.
  11. If all goes well you should a Microsoft Query window containing another a visual representation of the query you just created
  12. Click on the AQ$_MGMT_ADMINMSG_BUS_G table ( or which ever table you used in step 8 ) and press delete. The table should disappear from the screen.
  13. Click the SQL button (at the very top of the window) and paste your query into the the SQL box that opens up then click OK. (You can use the query builder features of Microsoft Query but,  to be honest, that can take a while. What i usually do is take my base query (click here to see it or download it here: sample_oemrep_query.sql) and paste that in). NOTE: this query returns daily summaries up until the day before today – the query won’t return any data for today.
  14. Change your parameters to suit and Save the query if you wish (Irecommend this).
  15. Then click the Return Data button (its at the top of the window to the immediate left of the SQL button). You should find yourself back in Excel territory.
  16.  Choose where you want to put the data and click ok. You should have a spreadsheet full of Enterprise Repository data.
  17. Create charts and graphs and pivot tables and pivot charts to your heart’s content.

Beware! There is a caveat:

Your date must be formatted as YYYY-MON-DD or MS Query will have a fit. Your query, if you’re going to query on dates must contain something like:

MGMT_METRICS_1DAY.ROLLUP_TIMESTAMP>TO_DATE('2012-JAN-01','YYYY-MON-DD')

or for the last 90 days worth of metrics data..

MGMT_METRICS_1DAY.ROLLUP_TIMESTAMP >= SYSDATE - 90

 

Leave a comment if this is any use to you.

Video (and amendments coming soon!).
Seamus.

Silverlight with Web Developer Express 2010 for free

If you want to get jiggy with Silverlight and don’t want to spend a load of cash on a version of Visual Studio one has to pay for then rejoice.

It seems one can install Visual Web Developer Express 2010 followed by the Visual Studio 2010 Service Pack 1 followed by  Silverlight 5 Tools for Visual Studio 2010 and all of sudden you will be able to develop Silverlight applications and what not for free… which is nice.. cheers Micro$oft.

 

 

Seamus

Kill oracle session from within pl/sql package

This isn’t great but its a start. Needed a quick and dirty routine to kill off some pesky discoverer sessions that had somehow (indirectly) locked a table.  Needs more work but here is version 1.0…

create or replace
PACKAGE DBA_UTILS AS 

  PROCEDURE KILL_DISCO_SESSION;

END DBA_UTILS;

create or replace
PACKAGE BODY DBA_UTILS AS

  PROCEDURE KILL_DISCO_SESSION IS
     CURSOR SESH is SELECT s.sid, s.serial# FROM gv$session s JOIN gv$process p ON p.addr = s.paddr AND p.inst_id = s.inst_id WHERE  s.type != 'BACKGROUND' and s.username = 'APPS' and upper(s.program) like 'DIS%';
     SESHINFO SESH%ROWTYPE;
     KILL_SQL_STATEMENT VARCHAR2(500);
     V_CURSOR_NAME_SESSION_KILL NUMBER;
     V_EXEC_SESSION_KILL NUMBER;
  BEGIN
    open SESH;
    loop
      fetch SESH into SESHINFO;
      exit when SESH%NOTFOUND;
      KILL_SQL_STATEMENT := 'alter system kill session ''' || SESHINFO.SID || ',' || SESHINFO.SERIAL# || '''' || ' IMMEDIATE';
      DBMS_OUTPUT.put_line(KILL_SQL_STATEMENT);
      ---
      V_CURSOR_NAME_SESSION_KILL := DBMS_SQL.OPEN_CURSOR; -- OPEN A CURSOR
      DBMS_SQL.PARSE(V_CURSOR_NAME_SESSION_KILL, KILL_SQL_STATEMENT, DBMS_SQL.NATIVE); -- PARSE SQL
      V_EXEC_SESSION_KILL := DBMS_SQL.EXECUTE(V_CURSOR_NAME_SESSION_KILL); -- EXECUTE THE STATEMENT
      DBMS_SQL.CLOSE_CURSOR(V_CURSOR_NAME_SESSION_KILL); -- CLOSE THE CURSOR
      ---
    end loop;
    close SESH;
  END KILL_DISCO_SESSION;
END DBA_UTILS;


Credit and respect to the dbForge Team Blog for providing some very useful info. I’ve used a couple of lines of their code prior to the end loop.

 

Seamus