eddie

your baddie teddie since 1983.

Category: tech (page 2 of 3)

Mounting NFS file share for Oracle database




When installing an Iomega NAS to do Oracle database backup over network for a client, i came across a problem when mounting the NFS file share.

ORA-27054: NFS file system where the file is created or resides is not mounted with correct options

It turns out that Oracle requires a certain set of NFS mount options to work properly. After much testing and research online, i’ve collated the below options that works well for Oracle database mounts or backup over direct NFS (no buffer, direct I/O):

Solaris
rw,bg,hard,nointr,rsize=1048576,wsize=1048576,proto=tcp,noac,forcedirectio, vers=3,suid
AIX (5L)
cio,rw,bg,hard,nointr,rsize=1048576,wsize=1048576,proto=tcp,noac,vers=3,timeo=600
HP-UX 11i v3
rw,bg,vers=3,proto=tcp,noac,forcedirectio,hard,nointr,timeo=600,rsize=1048576,
wsize=1048576,suid
Linux x86
rw,bg,hard,nointr,rsize=1048576,wsize=1048576,tcp,actimeo=0,vers=3,timeo=600
Linux x86-64
rw,bg,hard,nointr,rsize=1048576,wsize=1048576,tcp,actimeo=0,vers=3,timeo=600

How to Jailbreak your iPhone 5, 4S, 4, 3GS or any iOS 6.x iDevice with evasi0n





Finally, evasi0n, the untethered jailbreak for iOS 6.x devices is here, meaning you can reboot your phone just like you normally would after the jailbreak.

 

List of compatible devices:

  • iPhone 3GS | 6.0, 6.0.1, 6.0.2, 6.1
  • iPhone 4 | 6.0, 6.0.1, 6.0.2, 6.1
  • iPhone 4S | 6.0, 6.0.1, 6.0.2, 6.1
  • iPhone 5 | 6.0, 6.0.1, 6.0.2, 6.1
  • iPod touch 4G | 6.0, 6.0.1, 6.0.2, 6.1
  • iPod touch 5G | 6.0, 6.0.1, 6.0.2, 6.1
  • iPad 2 | 6.0, 6.0.1, 6.0.2, 6.1
  • The New iPad (third generation) | 6.0, 6.0.1, 6.0.2, 6.1
  • iPad With Retina Display (fourth generation) | 6.0, 6.0.1, 6.0.2, 6.1
  • iPad Mini | 6.0, 6.0.1, 6.0.2, 6.1

As always, backup your data via iCloud over-the-air, or via iTunes in case something goes wrong.

Tested evasi0n on Mac OSX 10.8 with no problems. iPhone 5 (GSM) jailbroken in less than 5mins. Downloading packages from Cydia remains a challenge at this point due to sudden uptake in traffic. Tried to install SBSettings a couple of times but is getting timeouts on certain packages.

Download links for Windows/Mac/Linux on official site: http://www.evasi0n.com

Guides for using evasi0n from iClarified and ModMyi.

Credits to evad3rs team for making this jailbreak possible!


Linux / Unix / Mac crontab – how to add, install or list jobs

Different Types of cron Configuration

There are two different types of configuration files:

  1. The UNIX / Linux system crontab : Usually, used by system services and critical jobs that requires root like privileges. The sixth field (see below for field description) is the name of a user for the command to run as. This gives the system crontab the ability to run commands as any user.
  2. The user crontabs: User can installer their own jobs using the crontab command. The sixth field is the command to run, and all commands run as the user who created the crontab

How Do I Install / Create / Edit My Own Cronjobs?

To edit your crontab file, type the following command at the UNIX / Linux shell prompt:
$ crontab -e

Syntax of crontab (Field Description)

Your cron job looks as follows for user jobs:

 1 2 3 4 5 /path/to/command arg1 arg2

OR

 
1 2 3 4 5 /root/backup.sh

Where,

  • 1: Minute (0-59)
  • 2: Hours (0-23)
  • 3: Day (0-31)
  • 4: Month (0-12 [12 == December])
  • 5: Day of the week(0-7 [7 or 0 == sunday])
  • /path/to/command – Script or command name to schedule

 

Easy to remember format:

* * * * * command to be executed
- - - - -
| | | | |
| | | | ----- Day of week (0 - 7) (Sunday=0 or 7)
| | | ------- Month (1 - 12)
| | --------- Day of month (1 - 31)
| ----------- Hour (0 - 23)
------------- Minute (0 - 59)

 

Your cron job looks as follows for system jobs:

1 2 3 4 5 USERNAME /path/to/command arg1 arg2

OR

1 2 3 4 5 USERNAME /path/to/script.sh

Example: Install Backup Job Script

If you wished to have a script named /root/backup.sh run every day at 3am, your crontab entry would look like as follows. First, install your cronjob by running the following command:
# crontab -e
Append the following entry:
0 3 * * * /root/backup.sh
Save and close the file.

More Examples

To run /path/to/command five minutes after midnight, every day, enter:

5 0 * * * /path/to/command

Run /path/to/script.sh at 2:15pm on the first of every month, enter:

15 14 1 * * /path/to/script.sh

Run /scripts/phpscript.php at 10 pm on weekdays, enter:

0 22 * * 1-5 /scripts/phpscript.php

Run /root/scripts/perl/perlscript.pl at 23 minutes after midnight, 2am, 4am …, everyday, enter:

23 0-23/2 * * * /root/scripts/perl/perlscript.pl

Run /path/to/unixcommand at 5 after 4 every Sunday, enter:

5 4 * * sun /path/to/unixcommand

Task: List All Your crontab Jobs

Type the following command :

# crontab -l
# crontab -u username -l

To remove or erase all crontab jobs use the following command:

# crontab -r
crontab -r -u username

 

adapted from cyberciti.biz

Benks Magic HSR on HTC One X





My brother and i both bought the HTC One X about 3 months ago. He recently purchased a Benks Magic HSR SP for me, after my HTC Original SP got scratched badly.

This is the first time i’m using the Benks series of screen protector. I’ve used SGP(Spigen), PowerSupport, Tunewear, PhoneDevil (from US), BodyGuardz and some random cheap SP before this (on the iPhone 3G, 3GS, 4, 5). The HTC One X is my first Android phone. I had the Samsung Galaxy Tab 10.1 prior to his, but sold it after a few months cause the performance was not up to my standard.

Anyway some information about the Benks screen protectors. They come in 4 flavours:

  • AR – Clear surface with Anti-reflection coating
  • SR – Matte surface, anti fingerprint, scratch resistant, anti-fog
  • HR – High transparency and scratch resistant
  • HSR – HD High clarity with anti-fingerprint and scratch resistant

Naturally the HSR is their flagship screen protector.

The level of detail they spent on the packaging of the screen protector pack is fantastic:

  • The screen protector is sealed in the green packaging. The packing is similar to those that holds the wet tissues when we visit a Chinese restaurant.
  • The electrostatic dedusting film, dedusting cleaning film and replacement pulling tags are sealed in the blue packing. (3,4,5)
  • Micro-fibre cloth and a tool to install the camera protector (6)

The tools provided will highly increase the likelihood of a successful installation of the screen protector. For those of us who has experience with installing screen protectors, you will know that the replacement pulling tag and the de-dusting film are essential. You will always get some pesky speck of dust going between the screen and the screen protector. The electostatic dedusting film is excellent for preparing the screen for installation.
Below is a short video that i took on testing the anti fingerprint claim on their HD high clarity screen. So far, i must say it’s pretty good.

The screen protector does not hinder the amazing 4.7″ HD screen on the One X, which providing adequate anti-fingerprint protection. Granted, if you have very greasy hands, there will still be fingerprints. But i’m happy to report that smudges wipes off easily on this screen protector. Also, it covers almost the whole screen, a stark contrast to the provided screen protector from SGP, which only covers the center portion of the screen.

Definitely recommended!

iPhone 5 pricing & model numbers – Australia, Canada, Hong Kong, Singapore, UK & Malaysia.





The new iPhone 5 was launched on September 21 in US, Australia, Canada, France, Germany, Hong Kong, Japan, Singapore, and the UK, and will be available in 22 more countries on September 28 and more than 100 countries by the end of the year. Malaysia is rumoured to get the iPhone 5 on October 26.

Continuing on my previous iPad 3 comparison table, i have compiled a comparative pricing table six countries – Australia, Canada, Hong Kong, Singapore, UK and subsequently Malaysia (when it is available). Canada’s pricing is probably the closest indicative pricing of an unlocked iPhone 5 in the US. I’ve also included model numbers to help you identify where you iPhone 5 is from if you purchased it at a mobile phone store and not from a telco or Apple Store.

I’m listing the native country’s currency pricing and USD conversion are done using prevailing exchange rate (as of October 4th 2012) from XE.com. All models listed below are GSM models, with the Canadian iPhone 5 being A1428 while the rest are A1429. For more information on what LTE bands the two different models support, go here.

Country16GB Model numbers (Black,White)Price (native)Price (USD)
AustraliaMD298X/A, MD297X/AA$799$816
CanadaMD293C/A, MD294C/AC$699$708
Hong KongMD298ZP/A, MD297ZP/AHK$5,588 $715
SingaporeMD298ZA/A, MD297ZA/AS$948$770
UKMD298B/A, MD297B/A£529$852
MalaysiaTBATBATBA
Country32GB Model numbers (Black,White)Price (native)Price (USD)
AustraliaMD299X/A, MD300X/AA$899$918
CanadaMD295C/A, MD296C/AC$799$810
Hong KongMD299ZP/A, MD300ZP/AHK$6,388$817
SingaporeMD299ZA/A, MD300ZA/AS$1,088$884
UKMD299B/A, MD300B/A£599$964
MalaysiaTBATBATBA
Country64GB Model numbers (Black,White)Price (native)Price (USD)
AustraliaMD662X/A, MD663X/AA$999$1,021
CanadaMD642C/A, MD643C/AC$899$911
Hong KongMD662ZP/A, MD663ZP/AHK$7,188$920
SingaporeMD662ZA/A, MD663ZA/AS$1,238$1,006
UKMD662B/A, MD663B/A£699$1,126
MalaysiaTBATBATBA


Singtel 4G LTE speed test on iPhone 5

One of the key new feature of the iPhone 5 is LTE. All 3 telcos in Singapore supports 4G LTE, with M1 touting nationwide support as of writing. My mobile phone carrier is SingTel, and on their 4G network coverage page (http://info.singtel.com/4G#Network_Coverage-tab), it states 50% as of June 2012, 80% on December 2013 and 95% coverage across the island in early 2013.

As i commute between home and office, i have tested SingTel’s 4G speeds in both location. I will continue testing LTE in various locations and update them here.

Home – Ang Mo Kio Street 12.

Office – North Canal Road (Clarke Quay)

ION Orchard

The lower speed in CBD area is probably attributed to the congestion that is slowly seeping onto the 4G network. As more users jump on the 4G LTE bandwagon, we may be back to the same overloading problem exhibited on the 3/3.5G network. The reduction in the download quota across all data plans would definitely weed out the bandwidth hogs, but telcos should also make sure that their infrastructure is capable of support the users subscribed to their service. A 4G capable phone is crippled without a decent mobile carrier to support it.


iPhone 5 pricing & release date – Singapore

Apple followed their previous pricing on the iPhone 4S for the new iPhone 5. It is expected to arrive in Singapore on September 21st.

  • 16GB – S$948
  • 32GB – S$1088
  • 64GB – S$1288


Apple iPhone 5 new features summary (updated)



Apple’s newly unveiled iPhone 5 is the thinnest smartphone on the market and the lightest iPhone yet, all while packing in a taller 4-inch Retina display and high-speed 4G LTE connectivity. It launches first on Sept. 21.

Pricing will be identical to previous years, with the 16-gigabyte model available for $199 with a new two-year contract, a 32-gigabyte model for $299, and 64-gigabyte for $399 in the US. For Singapore, the prices replicates the previous iPhone 4S pricing: 16GB for S$948, 32GB for S$1,088 and 64GB for $1,288. Preorders will begin this Friday, Sept. 14, and it will launch in the U.S., Canada, U.K., Germany, France, Australia, Japan, Hong Kong and Singapore on Sept. 21. An additional 22 more countries will get their iPhone 5 on September 28, including: Australia, Belgium, Czech Republic, Denmark, Estonia, Finland, Hungary, Ireland, Italy, Liechtenstein, Lithuania, Luxembourg, Netherlands, New Zealand, Norway, Poland, Portugal, Slovakia, Slovenia, Spain, Sweden and Switzerland. A further 20 more countries will get it in October. (updated)

All of the native applications in iOS have been updated to take advantage of the new, larger display. Apple marketing chief Phil Schiller showed off how Calendar shows off a full five-day workweek, and how the iWork suite has been updated to use the expanded real estate.

Old applications will run letterboxed on the larger screen, with black borders on either side centering the application, allowing for what Schiller called “pixel-perfect” rendering. He said that developers will be able to quickly and easily updated their applications to take advantage of the new display.

The touch panel has also been integrated into the Retina display, allowing the screen to be even thinner and sharper, and produce less glare in sunlight. Schiller said the new screen has 44 percent better color saturation, with full sRGB rendering.

As with previous iPhones, the iPhone 5 will be available in two colors: black and white. The white model has a raw aluminum back, while the black version has a black anodized metal back.

The addition of 4G LTE and the A6 CPU will not have a negative effect on battery life, according to Apple. Schiller said that the new iPhone 5 will not only match, but will exceed the battery life of the iPhone 4S, offering 8 hours of 3G or LTE talk time or Web browsing.

A new microphone has also been added to the back that will allow for improved audio recording and voice cancelation.

Another major feature of the new iPhone is 4G LTE connectivity, which allows for the fastest mobile connections available. The iPhone 5 also sports a dynamic antenna that switches between connections seamlessly.

The iPhone 5 will offer 4G LTE support on carriers AT&T, Verizon and Sprint in the U.S. In Canada, Rogers, Telus, Bell, Virgin and Fido are compatible. More carriers were also listed for Europe, Australia and Asia.

Wi-Fi connectivity is 802.11a/b/g/n, and is dual-channel for up to 150Mbps downloads.

The all-new A6 processor also promises up to twice as fast graphics and CPU performance. Schiller said the A6 will launch Pages more than twice as fast, save an image from iPhoto 1.7 times as fast, load the Music app with songs 1.9 times as fast, and view a Keynote attachment 1.7 times as fast.

The iSight camera has been upgraded to an 8-megapixel sensor that captures 3,265 by 2,448 pixels. It’s a five-element lens and f/2.4 aperture, while being thinner than the iPhone 4S.

Image capture is said to be 40 percent faster, while a new image processor in the A6 promises to reduce noise and accomplish better color matching.

Also built in to the iOS 6 camera application is support for panoramic photos.Users simply sweep the scene vertically to maximize resolution, which can result in a 28-megapixel image.

The rear camera will record 1080p high-definition video and has improved video stabilization.  Sapphire crystal lens prevents scratches that distorts photo and video taking. The forward-facing FaceTime HD camera also records 720p video, and has backside illumination.

The thinner iPhone is made possible in part by a new, smaller 9-pin dock connector dubbed “Lightning“. Adapters will also be available to ensure compatibility with legacy accessories.

Credit: Images are from respective sites like Engadget/Anandtech. Notes from AI.

“Official” Apple iPhone 5 advert promo video – leaked

I must say, even Apple fan-boys are amazing when it comes to making “rumoured” mock-ups of new products and apple-esque product advertisements.

Just hours before the September 12th Apple launch event, MacObserver found a brilliant iPhone 5 promo video. Granted it’s probably not the “official” video by Apple, but the effort in making such a detailed video deserves some credit. Enjoy.


Microsoft Excel Macro – Search and replace

While covering for my colleague at a PremierCare site, the marketing manager wanted to see if i could help him with some basic search and replace macros to eliminate the need for his manual data cleanup when he export reports from the database.

He wanted to change items codes into names (e.g 123 -> Hotel) and country common names to ISO 3166 2-letter (alpha-2) codes (e.g Japan -> JP).

For changing of common country names to alpha-2 codes:

Sub multiFindNReplaceCountries()
 Dim myList, myRange
 Set myList = Sheets("Country Codes").Range("A2:B273") 'two column range where find/replace pairs are
 Set myRange = Sheets("Report").Columns(1) 'range to be searched
 For Each cel In myList.Columns(1).Cells
 myRange.Replace what:=cel.Value, replacement:=cel.Offset(0, 1).Value
 Next cel
 End Sub

This select a list of country names from the worksheet labelled” Country Codes”, from Range A2 to B273. First column (A) is where i have the full country name, and 2nd column (B) is where i have the 2-alpha country code. There are a total of 273 entries, hence i select the range to B273.

The worksheet that i want to do the search and replace is called “Report”. The country names are all on the first column of the worksheet, hence in myRange, i have it set to Columns(1), indicating that the first column are the cells that the script needs to perform the search and replace.

For changing of ID codes to their respective descriptions:

Sub multiFindNReplaceCode()
 Dim myList, myRange
 Set myList = Sheets("Codes").Range("A2:B53") 'two column range where find/replace pairs are
 Set myRange = Sheets("Report").Rows(1) 'range to be searched
 For Each cel In myList.Columns(1).Cells
 myRange.Replace what:=cel.Value, replacement:=cel.Offset(0, 1).Value
 Next cel
 End Sub

This select a list of codes from the worksheet labelled “Codes”, from Range A2 to B53. First column (A) is where i have the codes, and 2nd column (B) is where i have the full descriptive names. There are a total of 53 entries, hence i select the range to B53.

The worksheet that i want to do the search and replace is called “Report”. The codes span horizontally across Row 1, hence in myRange, i have it set to Rows(1), indicating that the first row are the cells that the script needs to perform the search and replace.

Just insert a module using the VBA Macro editor in your excel (or press Alt + 11), past the above and change the worksheet names, run the script and you should see the values automatically updated.

Older posts Newer posts

© 2018 eddie

Theme by Anders NorenUp ↑