SQL Developer SSH Connections In Depth

Capture

Available now: A 29-page white paper on SQL Developer SSH Connections that explains in detail how SSH connections should be configured between your desktop/laptop and your organization’s database!

The vast majority of explanations out on the internet of how to configure SSH connections between Oracle SQL Developer and an Oracle Database use incredibly simplistic explanations, often using the oracle os account as the ssh user (absolutely a worst practice!), and not including important things like how firewalls will impact connections, how your ssh server should be configured, etc.

I wrote a 29-page white paper which has been published on the Insum.ca website. It covers the above and more in exacting detail. If you click the link above you’ll be taken to a description of the white paper and then to a page where you’ll be able to download it after supplying a name and email (a fair trade for the amount of time and effort I put into the white paper…).

Note: The image above is from the white paper and is used for explanation purposes only… None of those things actually exist except for the WordPress external firewall that protects just this blog, or, actually, all the blogs at WordPress.com.

Advertisements

Thoughts on the line at CotA

CotA Track Map
After many thousands of laps at CotA I can say for certain that the turns that most folks have trouble with are the following:
  1. Turn 3
    CotA Track Map - Turn 3.PNG
    You should enter turn 3 from as far LEFT as you feel comfortable. You should NOT go to the right side of the track to enter turn 3. Ideally you are carrying as much speed as possible through 2 and are brushing your driver’s side (assuming left hand drive car here) wheels right over the edge of the apex curbing at 3 on your way into the apex of 4. Cars end up in the wall on the exit of turn 3/entrance to turn 4 because they tried to enter 3 from the right hand side of the track. I believe the thought is that “Turn 3 is a left hand turn, you should enter it from the right side of the track.”, but turn 3 leads directly into turn 4, so driving from apex to apex in a straight line through 3 and 4 is MUCH more efficient and much, much safer.
  2. Turn 7
    CotA Track Map - Turn 7-8-9
    Turn 7 is one of the two more important turns on the track as it is one of the two INCREASING radius turns on the track (the other being  turn 19, see below). Instead you should take care to NOT late apex 7 and to track out of turn 7 to the right hand side of the track and then throw away turn 8. Unless you are driving a tricycle you are going to be traction limited going through turn 9, so entering turn 8 from the right hand side of the track (to get a ‘good run up the hill’) is just plain silly.
  3. Turn 8
    See above. Enter turn 8 basically ON the curbing on the right hand side of the track and force the car over to the right as much as possible to open up turn 9. Turn 8 is the throw away turn.
  4. Turn 13
    CotA Track Map - Turn 13

    Turn 13 is often taken too fast and early apexed which leads to throttle bobble as you are exiting 13 (or going wide and off track). Instead take 13 a bit deeper and brake a bit harder and turn in a bit harder so that you apex 13 a bit later than you think you should and you’ll be able to constantly add throttle all the way into 15.
  5. Turn 19
    CotA Track Map - Turn 19

    Turn 19 is an increasing radius turn, so it can be taken much, much earlier and much, much faster than most do.

The rest of the track is mostly just ‘regular’ corners and most get them mostly right.

However, the above corners are where my green, first day ever, students often end up being significantly more efficient around the track than just about everybody else in the run group, often to the point where the student will ask me “Why are they going over there to enter turn three?”, or “Why are they going over there to enter turn eight?” while we basically coast behind them off throttle so that we can give the car in front of us enough room to get through the corner. My answer “I’m not really sure why, but as you can see we are significantly more efficient by taking this line, aren’t we?” and, every single time, I get a very enthusiastic “Yes!”.

This also applies to MANY of the advanced students that I coach.

Data analysis bears out the above too…

 


Rich Soule Racing adds a new car to the fleet

It all began with a trip to the incredibly dangerous BringATrailer.com

I’d had a 2004 Radical SR3 for a number of years which I loved, but a 2008 Radical SR3 done up like a Mazda 787B came up for sale and on a lark, I threw in a very low bid. The 787B liveried Radical was four years newer and also had a very desirable (and expensive) paddle shifter upgrade and a spare set of wheels. Who knows, maybe nobody else would bid… Four days later the auction was coming to an end and the car still hadn’t hit market value. Maybe I could grab it? I put in a bid at way under market value and watched the timer go down. A new bid came in, so I put in a new slightly higher bid. This kept on going back and forth for the next (very stressful) 11 minutes (Bring A Trailer always leaves the auction open for two minutes after any bid, so there is no sniping…). At the end of that 11 minutes I saw this:

Capture

Wow!

I’d gone from this:

IMG_0334

to this:

3AE96891-B553-4F62-BE6D-096BF82FC74F-7827-000008D84179DC70

This led to a number of issues:

  • I now had two Radicals.
  • I had to explain to my wife why this was a good thing.
  • The new Radical was in Los Angeles and I live in Austin.

A quick conversation with the seller solved issue 1. He’d sell my older Radical for me.

The 2nd issue was a bit harder to resolve, but having the first issue solved sort of helped me a bit. I also reminded my wife that I’d be very happy with the newer car and I’ve always appreciated how much she values my happiness. I also got her a dozen roses delivered to her office. I think I’ll be OK on this one.

Depending on what my first Radical goes for, I might come out of this pretty clean. I did get the 2nd car at the lower end of market value and it did have a very nice set of extra wheels with brand new tires. Add in the pneumatic paddle shifters and I don’t think I would have been able to add those upgrades to my current car without going over the purchase price of the new car minus the sales price of my old car (we’ll see what my old car goes for…).

The final issue began this past weekend’s great adventure. When I first purchased the white Radical that meant I’d have to get a truck and trailer. Since both my wife and I instruct for various organizations I ended up getting a two car covered trailer and an (older) F350 dually.

IMG_3630

A friend of mine had a Radical Pro Sport that he had purchased from Bring A Trailer, but the organizations he was running with wanted him to only run it in the instructor run groups, so he was looking to let someone else have fun with it. His car was down in Houston. The seller of my new car said he’d also sell my friend’s Pro Sport. Thus a plan was born: Drive to Houston, pick up friend’s car, drive to LA, drop off both cars, load up new car and drive back to Austin. Planned travel time: Friday to (very, very early) Monday morning. I knew this was pushing it, but hey, why not?

Last Friday I took off from Austin and drove down to MSR Houston to pick up my friend’s Pro Sport. It took a bit to pack everything up (lots of spares) and then I headed out to Los Angeles. Unfortunately, the dually had a blowout in one of the inside rear tires as I was driving on I10, but luckily for me, this happened before I got past San Antonio.

IMG_3634.jpg

I very carefully and slowly drove back to Austin (everywhere that could have fixed the tire was closed at this point), spent the night with Stacy and then took the truck over to Don Rucker Tire and Wheel first thing in the morning. We decided to replace all the tires on the rear of the truck and I headed back out to LA.

It was quite a trip.

  • Times I ran out of gas: 1
    (GPS said there was a gas station just down the road, but when I got there they were out of diesel)
  • Times I almost ran out of gas: 2
    (Again, iExit/Waze/Google said there was a gas station, but when I got there… nothing.)
  • Times I got the truck and trailer stuck in mud: 1
    (The Wilcox AZ Holiday Inn and Suites had a big dirt lot that they made me park in. While I slept, rain happened. Then this happened:
    IMG_3641
    The tow truck barely had to help me get out, but help me out he did.)
  • Miles driven: 2,890
  • Miles driven on I10: @2,475
    (Goodness gracious this is a boring drive, but when you are towing a 44′ trailer behind an F350, boring isn’t all horrible.)
  • Dollar Amount of Gas Purchased: $814.48
    (I kind of think there might be some pending charges as this doesn’t seem like all that much).
  • Hotel stays: 2
  • Truck Naps: 1 (about an hour or so)
  • Hours spent over the whole trip: @88.5
    (Between the stop in Austin to get the blowout fixed and the stops along the way, I didn’t get back in Austin until 4:30 am on Tuesday morning).
  • Daniel McFadden’s seen: 1
    (I was Daniel’s first ever instructor at an HPDE a long time ago. Daniel is now an instructor himself and lives out in LA. He came over to say hi when I picked up the new car in LA.IMG_3647)
  • Number of Tuckers seen: 1
    IMG_3651
    This is Preston’s actual car that he drove away from the courthouse after he won the case that cleared his name. Unfortunately, it was too late at that point and Tucker Automobile never happened.

At this point I’m just looking forward to the next event at CotA (or somewhere else) so I can drive the car on track.

If you see me there, please feel free to ask for a ride.

Rich


Did your APEX upgrade just fail with ORA-04043: object WWV_DBMS_SQL does not exist?

FailedAPEXInstall

Many folks have done upgrades of APEX to later versions of 5 or 18 without any issues at all, but there is a situation in which things can go wrong. I’m not exactly sure how much of an edge case it is, but I’ve now seen it ‘more than once’. I know that it requires a 12.2 or higher database and I believe it might require an APEX that has been upgraded over the years from ‘previous releases’, somewhere between 3 and 5.0, to a 5.1 or higher version of APEX such as the current 18.1 version of APEX.

In Oracle Database 12.2 and higher, the following three APEX package was officially deprecated or dropped: WWV_DBMS_SQL, WWV_FLOW_VAL, and WWV_FLOW_KEY. Note that I tried to find something in the official Oracle Documentation on this, but I couldn’t. (I’m sure someone with better Google-foo than I could, but it would seem that Oracle’s search capabilities for its documentation should really be a lot better than they are…)  Here’s a link to Morgan’s Library where he lays out what’s different in 12.2 and you can see these three objects are in the deprecated or dropped list. Update: Only WWV_DBMS_SQL was deprecated. The issue that we’re going to run in to is that, most definitely, WWV_DBMS_SQL has been dropped deprecated in Oracle Database 12.2. Update: WWV_FLOW_VAL and WWV_FLOW_KEY are not deprecated or dropped, they are just no longer installed by default as APEX is no longer installed by default. WWV_FLOW_SQL is deprecated.

During the APEX 18.1 install, it will look for a previous version of APEX and when it creates the new APEX_180100 schema, it will migrate all of your information from the previous APEX schema (let’s say APEX_050100) into the new schema. One VERY cool thing about this is that the install will leave all data in the previous schema so that if the installation fails, you can use these instructions to revert back to your previous installation. If you read the documentation that I linked you’ll see that for reverting to a lot of the older versions of APEX after the 18.1 install fails, you’ll actually add back the WWV_DBMS_SQL package by running the source which is in the $ORACLE_HOME/apex/core folder.

After the migration is complete, the installer will attempt to ‘clean up’ some artifacts from the previous versions of APEX that might otherwise get left behind so might run into the following situation if you have a 12.2 or higher database:

SYS@prodcon AS SYSDBA> @apexins apex apex_files temp /i/
[SNIP of vast amounts of output]
PL/SQL procedure successfully completed.

...Remove objects created from previous APEX installations
declare
*
ERROR at line 1:
ORA-04043: object WWV_DBMS_SQL does not exist
ORA-06512: at line 9
ORA-06512: at line 23

Disconnected from Oracle Database 12c Enterprise Edition Release 12.2.0.1.0 - 64bit Production

If I used the version of APEX that ships with the 12.2 database to add back in the WWV_DBMS_SQL (from the $ORACLE_HOME/apex/core folder run wwv_dbms_sql.sql and wwv_dbms_sql.plb files as sys) I’d get the ‘new updated versions’ (see below) that actually create a specific version of the packages with the APEX schema name in it, instead of the old ‘generic’ WWV_DBMS_SQL. I had to go back to an older version of APEX (I grabbed one from our previous 12.1 version of the database, but of course you could just download an older version of APEX from the previous versions download page on Oracle.com). I’d suggest anything in the 5.0 timeframe.

Here’s what I finally ended up with in my database after the now successful 18.1 upgrade from a 5.1 previous version after running the correct WWV_DBMS_SQL code. Rather hilariously, the error that ended my previous upgrade attempt where it appeared that the install failed because it couldn’t drop the WWV_DBMS_SQL package appears to not actually be the case because I still have the WWV_DBMS_SQL package in my database:

select owner, status, object_name, object_type
  from dba_objects
 where object_name like 'WWV_DBMS_%'
   and owner='SYS';
OWNER   STATUS    OBJECT_NAME                OBJECT_TYPE    
SYS     VALID     WWV_DBMS_SQL               PACKAGE        
SYS     INVALID   WWV_DBMS_SQL               PACKAGE BODY   
SYS     VALID     WWV_DBMS_SQL_APEX_050100   PACKAGE        
SYS     VALID     WWV_DBMS_SQL_APEX_050100   PACKAGE BODY   
SYS     VALID     WWV_DBMS_SQL_APEX_180100   PACKAGE        
SYS     VALID     WWV_DBMS_SQL_APEX_180100   PACKAGE BODY   

6 rows selected.

Rows 1 and 2 came from the 12.1 version of APEX that shipped with the database, rows 3 and 4 were from the shipped version of 12.2 APEX and rows 5 and 6 are from the 18.1 version of APEX.

At this point, I can now clean up the database by dropping the WWV_DBMS_SQL and WWV_DBMS_SQL_APEX_050100 packages from the database.

Of course, I’ve asked Oracle Support to log a bug against the APEX install script. I’ll update this post with the bug number once Oracle Support is back online (they are doing upgrades this weekend, so Support has been offline a bit… Hmmm… Maybe they should be using #ThickDB with Edition-Based Redefinition to do live updates!)

Happy APEXing!

Rich


Beware: Oracle RMAN Password Only Encrypted Compressed Backups to Tape Might Not Decrypt

So, a few weekends ago I had a BIG scare. I was moving an Oracle Database Appliance from one data center to another. Oracle said the only supported method to do so was to wipe the machine back to bare metal and rebuild it in the new data center with all the new IP addresses and network settings. To prepare for this I did a cold backup of a database to tape (really Oracle Cloud Backup) and used the following RMAN commands:

RMAN> set encryption on identified by ******************* only;
RMAN> backup device type sbt incremental level 0
      tag '2018_06_29_SERVER_MOVE' force as compressed backupset database;

Unfortunately, when it came time to read that backup from Oracle Cloud Backup (our configured sbt device), I got the following error:

ORA-19913: unable to decrypt backup

As I worked through the issue with Oracle Support for a very long time I eventually started working with some support folks who said the following:

“I’ve seen issues in the past when you do a password only encrypted compressed backup to tape where it can’t be decrypted. You shouldn’t do that.”

I think this is potentially one of the biggest bugs in the history of Oracle (if you can’t trust a backup then something is very very wrong!) if the issue is really there… I’ve yet to be able to do any additional testing of this, but figured I’d give folks a warning.

As an aside, I did take a disk backup before the tape backup and then copied the disk backup to a mounted NFS drive. I was able to move that disk backup over to the server and restore from it, so no customer data was harmed during the server move.


I’ll be speaking at KScope18!

ODTUG
Today I got an email that began like this:

Dear Richard,

Congratulations on being selected to speak at the premier Oracle user group conference—ODTUG Kscope18. We had more than 1,000 abstracts submitted this year, making this selection a very challenging process.

The following abstract has been accepted for presentation at ODTUG Kscope18, June 10-14 in Orlando, Florida. If you submitted multiple abstracts, you will receive multiple emails with the status of each abstract.

Texas Racing Commission: Lessons Learned from Migrating to Oracle Cloud

——–

I also had another presentation that got accepted as a possible alternate:  Entity Relationship Modeling in the Age of Agile Development.

Hopefully I’ll see some of you at KScope in Orlando!

Remember to use code “insum” at checkout to get a discount off your registration.


Today C2 Consulting and Insum Solutions Merged

Capture

Today is my first day as Director of Consulting Services at Insum Solutions! I’m really excited to be part of the Insum team. Insum has been a (the?)  leader in the APEX consulting services space for many years. C2 and Insum have had very similar philosophies and execution styles. I’m really looking forward to working with the new (much bigger) team.

https://www.insum.ca/insum-and-c2-consulting-unite-to-better-serve-the-american-market/