Weblogic 12c | Admin Server startup error(s)

Hello guys

Two days back I’ve seen a tweet from Michael Ferrante asking the “Forms Enthusiasts” to hold their breathe, as Oracle is going to announce something “Exciting” for Oracle forms. Are you EXCITED as much I am? Well, I am pretty sure, it is going to be a push for AuraPlayer, as he has mentioned them in the tweet.

Regardless, I’ve a local instance of Weblogic Server, installed and a classic domain created. I stopped using it as my firm decided to drop the idea to migrate our 20+ years old Developer 6i developed ERP to Weblogic due to the complexity of Oracle licensing, followed by the uncertainty of Oracle support for Oracle forms beyond 2025 (Which is just 6 years away).

Hell with it, I wanted to see how far I have configured the domain and ended up setting up the forms server, publishing the half baked legacy application. As I have made more than dozen Weblogic installations in last 2-3 years time, I had almost everything backed up from different installations like configuration files, environment and registry files. All I needed was to copy and replace them at most of the places to bring the legacy application online within couple of hours time.

However, I have noticed that while starting the Weblogic Admin Server (from the command prompt, using supplied .cmd files), I was getting a number of java errors & all of them were related to FADS (Forms Application Development Services) & some text were like below (Sorry for the wrapping issues)

weblogic.application.library.LibraryDeploymentException: [J2EE:160141]
Could not initialize the library Extension-Name: fads-dbtools-library.
Ensure that the deployment unit is a valid library type (WAR, EJB, EAR, plain JAR).
(The system cannot find the file specified) with :
at weblogic.application.internal.library.LibraryDeploymentFactory.getLibData(LibraryDeploymentFactory.java:98)
at weblogic.application.internal.library.LibraryDeploymentFactory.createDeployment(LibraryDeploymentFactory.java:50)
at weblogic.application.internal.DeploymentManagerImpl.createDeployment(DeploymentManagerImpl.java:195)
at weblogic.application.internal.DeploymentManagerImpl.access$800(DeploymentManagerImpl.java:61)
at weblogic.application.internal.DeploymentManagerImpl$DeploymentCreatorImpl.createDeployment(DeploymentManagerImpl.java:628)
Truncated. see log file for complete stacktrace

weblogic.application.internal.DeploymentStateChecker$DeploymentAssertionError: Unexpected transition: current state for application fads#1.0 : STATE_NEW attempt to transition to STATE_ADMIN
Dumping 2 callbacks
java.lang.Exception: prepare
at weblogic.application.internal.DeploymentStateChecker.save(DeploymentStateChecker.java:152)
at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:157)
at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:65)
at weblogic.deploy.internal.targetserver.AppDeployment.prepare(AppDeployment.java:166)
at weblogic.management.deploy.internal.DeploymentAdapter$1.doPrepare(DeploymentAdapter.java:41)
at weblogic.management.deploy.internal.DeploymentAdapter.prepare(DeploymentAdapter.java:193)
at weblogic.management.deploy.internal.AppTransition$1.transitionApp(AppTransition.java:31)
at weblogic.management.deploy.internal.ConfiguredDeployments$2.doItem(ConfiguredDeployments.java:741)
at weblogic.management.deploy.internal.parallel.BucketInvoker$2.run(BucketInvoker.java:95)
at weblogic.work.ContextWrap.run(ContextWrap.java:46)
at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:670)
at weblogic.invocation.ComponentInvocationContextManager._runAs(ComponentInvocationContextManager.java:352)
at weblogic.invocation.ComponentInvocationContextManager.runAs(ComponentInvocationContextManager.java:337)
at weblogic.work.LivePartitionUtility.doRunWorkUnderContext(LivePartitionUtility.java:57)
at weblogic.work.PartitionUtility.runWorkUnderContext(PartitionUtility.java:41)
at weblogic.work.SelfTuningWorkManagerImpl.runWorkUnderContext(SelfTuningWorkManagerImpl.java:644)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:415)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:355)
java.lang.Exception: activate
at weblogic.application.internal.DeploymentStateChecker.save(DeploymentStateChecker.java:152)
at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:164)
at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:90)
at weblogic.deploy.internal.targetserver.BasicDeployment.activate(BasicDeployment.java:274)
at weblogic.deploy.internal.targetserver.BasicDeployment.activateFromServerLifecycle(BasicDeployment.java:507)
at weblogic.management.deploy.internal.DeploymentAdapter$1.doActivate(DeploymentAdapter.java:53)
at weblogic.management.deploy.internal.DeploymentAdapter.activate(DeploymentAdapter.java:202)
at weblogic.management.deploy.internal.AppTransition$2.transitionApp(AppTransition.java:52)
at weblogic.management.deploy.internal.ConfiguredDeployments$2.doItem(ConfiguredDeployments.java:741)
at weblogic.management.deploy.internal.parallel.BucketInvoker$2.run(BucketInvoker.java:95)
at weblogic.work.ContextWrap.run(ContextWrap.java:46)
at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:670)
at weblogic.invocation.ComponentInvocationContextManager._runAs(ComponentInvocationContextManager.java:352)
at weblogic.invocation.ComponentInvocationContextManager.runAs(ComponentInvocationContextManager.java:337)
at weblogic.work.LivePartitionUtility.doRunWorkUnderContext(LivePartitionUtility.java:57)
at weblogic.work.PartitionUtility.runWorkUnderContext(PartitionUtility.java:41)
at weblogic.work.SelfTuningWorkManagerImpl.runWorkUnderContext(SelfTuningWorkManagerImpl.java:644)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:415)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:355)
———————- END CALLBACK DUMP ——-
at weblogic.application.internal.DeploymentStateChecker.throwAssertion(DeploymentStateChecker.java:88) at weblogic.application.internal.DeploymentStateChecker.illegal(DeploymentStateChecker.java:107) at weblogic.application.internal.DeploymentStateChecker.up(DeploymentStateChecker.java:122) at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:166) at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:90) Truncated. see log file for complete stacktrace

Basically, these errors NEVER truly interrupt anything with deploying a forms based application, unless you want to do more with FADS. FADS deployment looks for some specific libraries and missing them were generating the above errors. As I mentioned, for a classic domain, addressing this error may not be truly necessary (for testing). I just love NO errors under usual scenarios, hence decided to fix it.

I referred the below documents to find a proper solution

The 1st document insists that we must delete/rename the pre-installed SQLDEVELOPER (3.x) under ORACLE_HOME (eg: D:\Weblogic\Middleware\Oracle_Home) & install a version that is minimum 4.2, however doesn’t mentioned anything about the highest version supported.

After checking the fads configuration py file, I realized that the files FADS deployment trying to locate during the startup were NOT available with SQLDEVELOPER 18.x:


The 2nd document I referred explained about configuring FADS & the blogger used SQLDEVELOPER 17.2 for his exercise. Hence I downloaded the specific version 17.2, extracted and copied the folder “sqldeveloper” to ORACLE_HOME & followed the instructions as provided within the Oracle document.

Error while using SQLDEVELOPER 18.x

D:\Weblogic\Middleware\Oracle_Home\oracle_common\common\bin>wlst.cmd D:\Weblogic\Middleware\Oracle_Home\forms\fads\fads_config.py
Picked up JAVA_TOOL_OPTIONS: -Djava.vendor=”Sun Microsystems Inc.”
Initializing WebLogic Scripting Tool (WLST) …
Welcome to WebLogic Server Administration Scripting Shell
Type help() for help on available commands

fads configuration script
Admin Server will be shutdown by running this script.
Do you want to continue? [Y/n] :Y
You need to install Oracle SQL Developer 4.2 or higher under ORACLE_HOME. Did you install SQL Developer 4.2? [Y/n] :Y
SQL Developer 4.2 is not installed under D:\Weblogic\Middleware\Oracle_Home
Install it and run this script again.
Download Oracle Sql Developer from http://www.oracle.com.
Problem invoking WLST – Traceback (innermost last):
File “D:\Weblogic\Middleware\Oracle_Home\forms\fads\fads_config.py”, line 341, in ?
File “D:\Weblogic\Middleware\Oracle_Home\forms\fads\fads_config.py”, line 207, in fullConfig
NameError: system

Successful configuration using SQLDEVELOPER 17.x

D:\Weblogic\Middleware\Oracle_Home\oracle_common\common\bin>wlst.cmd D:\Weblogic\Middleware\Oracle_Home\forms\fads\fads_config.py
Picked up JAVA_TOOL_OPTIONS: -Djava.vendor=”Sun Microsystems Inc.”
Initializing WebLogic Scripting Tool (WLST) …
Welcome to WebLogic Server Administration Scripting Shell
Type help() for help on available commands

fads configuration script
Admin Server will be shutdown by running this script.
Do you want to continue? [Y/n] :Y
You need to install Oracle SQL Developer 4.2 or higher under ORACLE_HOME. Did you install SQL Developer 4.2? [Y/n] :Y
SQL Developer 4.2 is installed under D:\Weblogic\Middleware\Oracle_Home
connecting to WebLogic:
Please enter your username :weblogic
Please enter your password :
Please enter your server URL [t3://localhost:7001] :
Connecting to t3://localhost:7001 with userid weblogic …
Successfully connected to Admin Server “AdminServer” that belongs to domain “base_domain”.
Warning: An insecure protocol was used to connect to the server.
To ensure on-the-wire security, the SSL port or Admin port should be used instead.
obtaining Admin Server host/port information
Location changed to domainRuntime tree. This is a read-only tree
with DomainMBean as the root MBean.
For more help, use help(‘domainRuntime’)
fadsui.ear:-> D:\Weblogic\Middleware\Oracle_Home\user_projects\applications\base_domain\forms\fads\fads-ui.ear
webservices – http://localhost:7001/fads/apis (updated to
Totals {connections=1, rest=1, updated=1}
updating FADS OWSM policy
creating fads keystore
Already in Domain Runtime Tree
Keystore created
Already in Domain Runtime Tree
Key pair generated
Context is missing, therefore using current context “/WLS/base_domain”.
Successfully configured property “keystore.type”.
Successfully configured property “location”.
Successfully configured property “keystore.sig.csf.key”.
Successfully configured property “keystore.enc.csf.key”.
creating fads WSM policy set
Session started for modification.
Description defaulted to “Global policy attachments for RESTful Resource resources.”
The policy set was created successfully in the session.
Policy reference “oracle/multi_token_rest_service_policy” added.
The configuration override property “propagate.identity.context” having value “true” has been added to the reference to policy with URI “oracle/multi_token_rest_service_policy”.
The policy set restPolicySet is valid.
Creating policy set restPolicySet in repository.
Session committed successfully.
importing fads authorization policy
import fadsWSpolicy passed D:\Weblogic\Middleware\Oracle_Home\forms\fads\policy\fadsWSMPolicy.zip
Importing “META-INF/policies/oracle/binding_authorization_template_fads”
Successfully imported “1” documents
Location changed to edit custom tree. This is a writable tree with No root.
For more help, use help(‘editCustom’)
Starting an edit session …
Started edit session, be sure to save and activate your changes once you are done.
Saving all your changes …
Saved all your changes successfully.
Activating all your changes, this may take a while …
The edit lock associated with this edit session is released once the activation is completed.
Activation completed
shutting down the Admin Server
Shutting down the server AdminServer with force=false while connected to AdminServer …
Disconnected from weblogic server: AdminServer
shutting down the Admin Server
…….done with fads post configuration…………
please start the Admin Server

Exiting WebLogic Scripting Tool.

Once the configurations are successfully completed, the configuration process shuts down the Admin Server. Start the Admin Server & there should not be errors towards missing FADS libraries.




Windows 10 1903 | Oracle VirtualBox virtual machines will not start/open

Hello guys

This is a quick post towards one of the issues I faced once after enabling Windows Sandbox feature that was made available with Windows 10 1903. As Sandbox feature utilizes Hyper-V (regardless whether you have enabled it or not).

Once Sandbox feature enabled, Oracle VirtualBox 6.0.x fails to launch the Virtual Machines.

Although VirtualBox 6.0.x are supposed to support Hyper-V for acceleration, my attempts were futile, forcing me to disable the Sandbox feature, enter BIOS and browse through the virtualization settings.

I can’t say what has resolved the issues. I disabled Sandbox, restarted the box, was unable to launch the Virtual Machines.

Restarted the laptop, entered BIOS and insured that the virtualization was turned on & tried to launch the Virtual Machines and they opened.

So give it a try, if you are stuck with the following error while trying to open a Virtual Machine!

Call to WHvSetupPartition failed: ERROR_SUCCESS (Last=0xc000000d/87) (VERR_NEM_VM_CREATE_FAILED).



Windows Subsystem for Linux | Backup & restore

Hello guys

WSL 2 is almost here! and if you are here, reading this post. Please consider reading about WSL 2

During one of the recent chit-chats, few of my contacts were asking me about the “real” business sense behind Linux on Windows. It is simple. Microsoft is:

Going to integrate LINUX so deep within Windows that, in the very near future, one don’t have to run a separate LINUX Server. Simple like that.

After experimenting with KALI Linux WSL, I managed to install Xfce & XRDP on Ubuntu 18.04 WSL & the only few things I couldn’t do with the WSL was starting services automatically when the subsystem starts. There are hacks, well, I don’t think they really worth a try soon as Microsoft will BE bringing it on to WSL pretty soon.

Now, let us get back to the topic. I’ve installed Ubuntu 18.04 WSL nothing less than half dozen times. Every time something goes wrong & I am forced to uninstall and re-install the WSL to continue with additional experiments. My last attempt was to install Kubuntu desktop, that screwed my Xfce & after 2 days of continuous efforts to “fix” few “unknown” things, I had to uninstall one Ubuntu WSL that had a fully functional WordPress instance :(

So, I decided to learn how to backup a functional WSL, so that if something goes wrong, I can restore & continue

I’ve ready at few places that Windows 10 version 1903 comes with WSL backup functionality out of the box. Until you decide to upgrade your box to 1903, you may use the below for backing up your dear WSL instance.

I came across a pretty decent thread here & a user Jaime’s answer is the apt ONE, missing only few details like /tmp folder.

Make a tar ball as mentioned by Jaime

# cd /
# sudo tar vzcpf /mnt/c/tmp/ubuntu_`date +%Y%m%d_%H`.tar.gz --exclude=/proc --exclude=/dev --exclude=/mnt --exclude=/media --exclude=/lost+found  --exclude=/tmp --exclude=/sys  --exclude=/run / > /mnt/c/tmp/ubuntu_`date +%Y%m%d_%H`.log 2> /mnt/c/tmp/ubuntu_`date +%Y%m%d_%H`.error

Where /mnt/c is C:\> drive of your Windows Machine. You may change /mnt/c/ to /mnt/d/ or /mnt/e/, based on how your partitions are laid. Closely watch the excluded directories. You MUST exclude them.

My tar ball was around 1.5GB in size & I moved the tar ball to another machine which didn’t have WSL activated.

First you have to enable Window Subsystem for linux from Turn Windows Features on or off (If you are not restoring the backup to same Windows Machine). This will ask you to restart your Windows Machine.

Copy the tar ball to a folder, say, D:\wsl

Download launcher.exe from https://github.com/yuk7/wsldl

Copy launcher.exe to D:\wsl

If you are going to restore a Ubuntu 18.04 WSL rename launcher.exe to Ubuntu1804.exe & rename your tar ball to rootfs.tar.gz

Open an elevated command prompt & switch to D:\wsl

and just execute, for example “Ubuntu1804.exe”

It will take a while for the installation to complete. As the superuser thread states, it installs and opens the WSL for you. From next time, all you need to do is to start Ubuntu1804.exe & your WSL instance is up and running!

However, I had an issue with the restored instance. It was related to missing /tmp folder. I found a solution for it with nixcraft article.


Prior trying to start any sevices, those you were using with your backed up instance, make sure you create the /tmp folder like below

$sudo chown root:root /tmp
$sudo chmod 1777 /tmp

Now, try to start your services, start xrdp & enjoy!



Windows Subsystem for Linux | WSL | Ubuntu 18.04 with Xfce & Xrdp

Hello guys

As many of us know, starting from Windows 10 1803, Microsoft has made Windows subsystem for Linux running in the background even after the console windows are closed.

Definitely this is a gain for those developers who want to have a Linux environment available always, regardless whether the console windows open or not. My requirements towards the same is pretty limited, as I have live Linux systems for almost all my experiments. However, was never less motivated to explore the WSL environments.

Last time I posted a thread about installing and configuring Ubuntu 18.04 WSL and setting up apache, MySQL.

This time we will see how you could enhance your Ubuntu 18.04 WSL with a proper GUI (Desktop environment). I am sure, majority of the Windows users will appreciate a GUI to interact with Linux against the Linux geeks who prefer command line interactions. In addition, few editors like geany or gedit ONLY could be used in a GUI environment.

We will be using Xfce (light weight desktop manager) & XRDP to achieve the GUI requirements on Ubuntu 18.04 WSL

Fire up your Ubuntu 18.04, and update the instance to the latest

sudo apt update && sudo apt upgrade

This could take a while to complete depending upon your internet connection speed

Once the update & upgrade finished, we will install both Xfce & Xrdp in a single session

sudo apt install xfce4 xrdp

The installation should be pretty smooth and within few minutes everything should complete. Not a single attempt from my end failed to install both Xfce or Xrdp

Once the installation is over, we MUST make sure that the XRDP doesn’t use port 3389 which is used by Microsoft RDP (in case if your Windows 10 is already configured for RDP). Hence we will edit the XRDP configuration file with a different port, in our case 3390

sudo vi /etc/xrdp/xrdp.ini

Change the port from 3389 to 3390 & save the file.

Now we will try start the XRDP service

rajesh@rt04:~$ sudo service xrdp start
* Starting Remote Desktop Protocol server [20190509-12:13:49] [DEBUG] Testing if xrdp can listen on port 3390.
[20190509-12:13:49] [DEBUG] Closed socket 6 (AF_INET6 :: port 3390)
[ OK ]

That’s it

Open Remote Desktop Connection from your Windows Machine & log on!

Supply your WSL username and password. You can use ONE of the existing WSL usernames, in case if your WSL have more than one user.

One of the main issues I found using Xfce4 was few goodies like print screen should be installed by the user prior screenshot capturing could be made (I took screenshots from the remote session & copied them to Windows for this post). This will include adding new keyboard shortcut keys.

We’ll quickly see how to resolve the above said

First install missing “xfce4-screenshooter”

sudo apt install xfce4-screenshooter -y

Once the package installation finished, we will define a new keyboard shortcut that binds “Print Screen” physical button on the keyboard to Xfce4 screenshot shooter package.

Launch Applications -> Settings -> Keyboard

and using the “Add” button, Create a new shortcut. Xfce4 supports different switches to be used with screenshooter package. I’m using the “-f”, for full screen captures.

Be careful when you define the keyboard shortcuts. There is a space between the command and switches, for example

xfce4-screenshooter -f

There is a space between xfce4-screenshooter & the switch “-f”. Once after entering the command and pressing OK will ask you to tap the physical keyboard button that you want to bind with the command. Tap “PrtScr” or other button of your choice & that’s all. Your screen capture should work now.

So why one would even need a GUI over WSL. Well, my answer is short. I always dealt with systems those came with GUI. Many business applications could only be installed over a GUI equipped system. Plus, I am not a geek & after hundreds of attempts I cannot deal with a console based editor like VIM. I feel comfortable with geany/gedit than feeling geeky at mind.

Cheers guys, now your WSL have a GUI. Start think about what YOU can’t do with WSL!

Happy developing!



Oracle Reports Developer 10g (| Layout designer hangs

Hello guys

Update: 25th April 2019

It looks like, setting up the compatibility for Windows 7 solves the Reports Builder shaking, freezing behavior to a greater extend. Going on with the “Fix” as NOTHING else could be done with a product that is NOT anymore supported by Oracle.


I “trust” Microsoft and I do update my Work/Home/VMs regularly. Ahum! 99.9% of the times I never had to go back and fix anything, that .1% times, things went awfully bad.

I cannot confirm which update, certainly one update within last 2 months have made Oracle Reports Developer 10g/6i loads messier than earlier. Now both version of reports developer will NOT load the layout designer properly.

The interesting factor about the layout designer is:

It hangs more often when you have multiple reports opened from a single instance of the reports developer & you are switching between the layouts.

For example, if you opened Report 1’s layout & closed it, then opening the Report 2’s layout arrests the designer & all the toolbar icons and rest go astray (as you could see with above image) which will force you to end task the developer using Task Manager/or other known measures.

It is irky, shaky, yet you can do your work with multiple sessions of reports developer opened with only one report loaded. There are no guarantees that this IS the ultimate solution. I often have to terminate the report builder and restart it to do my development(s) :(

I’ve more news for you. I did a reinstall routine of Patch 3 for 10g developer & remembering Windows 7 was the last OS certified with the developer suite, changed the compatibility for the Report Developer and set it as Windows 7. I am not sure whether it acts as a mediator, my report builder is much stable as I am jolting these few lines. Keeping fingers crossed.


Linux Subsystem for Windows | WordPress

Hi guys

Almost a year back I posted about Linux Subsystem for Windows & interesting that I am revisiting the subject in the same period once again. Within an year time loads have changed with the Linux subsystem. Starting from Windows 10 version 1803, once started the Linux Subsystem is available in the background until a reboot! Sounds great?

This time we will see such an enhancement could be utilized on Windows for some extended “developments”, and I will walk you through setting up “WordPress” using WSL. Please note, I am opting “WordPress” as target ONLY for few reasons like:

  • “WordPress” is developed using PHP
  • “WordPress” mostly uses MySQL for database
  • “WordPress” is mostly hosted on LINUX environments

Windows SubSystem for Linux Installation

You must enable “Windows SubSystem for Linux ” through “Turn Windows Features on or off”, after which you will have to reboot your Windows box

Open “Windows Store” and search for Linux, that should bring up many results as seen with the image below

We’ll be using Ubuntu 18.04 LTS this time as I had pretty difficult issues with Pengwin & SUSE. If you are familiar with Linux, Ubuntu is a debian based Linux distribution & widely used for desktop systems. For our limited tests Ubuntu is a right choice.

Total download of Ubuntu 18.04 is around 270MBs & should be installed without giving any troubles.

Once “Ubuntu App” is installed you will be notified and you can immediately “launch” the app.

Ubuntu takes few minutes to finalize the installation & will prompt you to enter a username & password. Make sure you remember the username and password, forgetting may force you to reinstall Ubuntu.

Immediately after setting up a Linux username and password, we will make sure that the Subsystem is upgraded with all new packages.

(While apt & apt-get do almost the same thing, why “apt” is preferred? please read about it here)

Issue the command

$sudo apt upade

Once the update process finishes with the list of packages those could be upgrade, go ahead with upgrading the instance

$sudo apt upgrade

Depending upon the speed of your internet connection this could take a while.

Installation of PHP, Apache, MySQL & phpMyadmin on WSL

Install PHP

$sudo apt install php libapache2-mod-php

It shouldn’t take more than couple of minutes before PHP is installed.

Install Apache2 (Web Server)

Issue the following command at prompt($)

$sudo apt install apache2 or sudo apt-get install apache2

Apache installation should not take more than few minutes & we will see how to configure it bit later.

MySQL installation

I faced multiple issues installing MySQL on my Ubuntu based WSL. Few were merely because I was ignoring few pre-requisites like checking for already open ports on my Windows & other were due to lack of adequate amount of experiences with installing software on Linux

After a couple of failed attempts, I landed upon this page, which neatly explains how to use MySQL PPA in the place of Ubuntu’s default repositories for MySQL

I will make some fresh screenshots, that is for recent versions of MySQL installation using the MySQL PPA, because there are few more MySQL versions are supported currently using the same PPA

Configure MySQL PPA

Issue the following commands:

wget http://repo.mysql.com/mysql-apt-config_0.8.10-1_all.deb

followed by

$sudo dpkg -i mysql-apt-config_0.8.10-1_all.deb

This will provide you a graphical interface to select correct MySQL version for your requirements

Now, you must run update command once again

$sudo apt update

Now we have a conflict to resolve. As on date, the MySQL 5.7 repository signature is invalid, for the same reason the repository will be disabled. (I don’t know what kind of issues this could produce, so not taking any risks). Next step we will get a valid signature for the disabled repository and re-enable it

Issue the command (read more here https://tecadmin.net/expired-key-expkeysig-with-apt/)

$sudo apt-key adv --keyserver keys.gnupg.net --recv-keys 8C718D3B5072E1F5

Make sure the key that you want to resign is fed in correct. You MUST insure that the command completes successfully.

As we have enabled the repository by getting the new key, we can proceed to next step.

We will force the udpate process once again

$sudo apt update

You should get a notice that 1 package could be upgraded. So we will go ahead with upgrade.

$sudo apt upgrade

This will auto start the configuration window, all you need is to select ok and proceed

Make sure there are no new packages after the setup by issuing

$sudo apt update

Now we can start installing the MySQL 5.7 Server.
Please note, if you already have an instance of MySQL running on your Windows, the port 3306 will be in use (unless custom ports are used) & you WILL never able to complete the MySQL installation on WSL. Many undocumented errors will stop the MySQL installation, apparently without giving you the least ideas of what went wrong. So, make sure that the MySQL server is stopped and the port is not listening to port 3306. I don’t know another way to address this situation.

Issue the command

$sudo apt install mysql-server

You will be prompted for MySQL root account. I suggest using the same password across this particular setup so that you will not mess them up later stages.

Confirm the MySQL root password

That completes the MySQL 5.7 Server installation.

Now, let us try to start the MySQL 5.7 Server service.

MySQL 5.7 service is started now. So we can proceed to installing phpmyadmin, MySQL manipulation software.

Install phpmyadmin

Issue the following command

$sudo apt-get install phpmyadmin php-mbstring php-gettext

As we are using Apache2 as web server, make the selection by tapping the spacebar and Ok

You will be asked whether the database for phpmyadmin should be configured, You should select Yes, unless you want to do it later.

You will be asked to provide the a password now, that is for the phpmyadmin, use the same MySQL root password here (you can use a new password, just to avoid confusion, I use the same password everywhere)

You have to confirm the password.

Now you will be asked to enter the MySQL administrator(root) password, supply it

Confirm & wait for the phpmyadkin to complete the installation

Installation will notify you about Apache not being running, you can ignore the notice.

Now we will start the Apache Server. Couple of things you should take care with Apache & I will try to list few of them below:

As the WSL runs as another software on Windows, it is bind to experience conflicts. For example, if you already have IIS server listening to port 80, without changing the port information for Apache, will not able to start the server until the ports information is corrected within the Apache configuration file.

If you already have MS SQL server installed with reporting, the reporting engine listens to port 80, so even if you would stop or disable the IIS/WWP services, there is a possibility that port conflicts will arise. This will also prompt you to alter the default port mentioned in the Apache configuration file

So let us see how we are going to address such conflicts:

Edit the Apache ports configuration file

$sudo vi /etc/apache2

I opted for port 8088 (You can choose a port that is NOT used by Windows. Issue netstat -aon to get a list of ports open/listening on Windows from CMD

100% sure that you are going get presented with an annoying notice “
Protocol not available: AH00076: Failed to enable APR_TCP_DEFER_ACCEPT” which is easily addressable.

We will edit the apache configuration file to address this issue

issue the command

$sudo vi /etc/apache2/apache2.conf

& add “AcceptFilter http none” by the end of the file.

Save the configuration file & restart the Apache service.

As we have completed all the installations and managed to start the services successfully after fixing the configuration files, it is time to reboot.

WSL unfortunately doesn’t let you use “init 0”, or “init 6” to shutdown or restart the instance, instead you must use the Windows Services MMC for the same.

This will close all open Ubuntu “app” windows. You can restart the Ubuntu from the app list.

Once Ubuntu restarted, let us start the services

$sudo service apache2 start
$sudo service mysql start

Once the services are started, we will try phpmyadmin. As I mentioned already, I have set the port 8088 for Apache, hence I can access the phpmyadmin from the link http://localhost:8088/phpmyadmin

You can safely ignore the warnings, as the current version of phpmyadmin we installed from Ubuntu repos have certain conflicts with PHP 7.2

Install “WordPress”

“WordPress” is one of the leading CMS (Content Management Systems) with unlimited possibilities. Recently we switched our decade long joomla based corporate website to “WordPress” & after few days of interactions with the technology, I feel I would never look anywhere else.

Get “WordPress”

Issue the command

$wget https://wordpress.org/latest.tar.gz

This will download the latest “WordPress” to your home folder

Now we have to extract the downloaded file to right htdoc root. We are talking about the default configurations available with apache configuration files. Hence the wordpress should be extracted to ‘/var/www/hmtl/’ folder, which is a protected path. We’ll change the folder permissions temporarily to facilitate the extracting

$sudo chown 777 -R /var/www

now switch to ‘/var/www/html/’

Issue the command

$tar -xvzf /home/rajesh//latest.tar.gz

NB: Replace the pathname, please

Now we will create a new database for the “WordPress” using phpmyadmin

Create a new MySQL user

Give the newly created user database privileges, in my case, I created a new datbase called “intranet”.

Set all privileges. On a production environment, YOU are expected to set them wisely.

As all set with the database, we will install “WordPress” now

Access the link (please changed according to your setups)

http://localhost:8088/wordpress/wp-admin/install.php, that will take you to “WordPress” installation page immediately.

Supply all requested details

Now we have a problem, “WordPress” installation cannot write to “wp-config.php” file. This is due to linux file/folder permissions. Hence we will again change the permissions over ‘/var/www/’ folder

$sudo chmod 777 -R /var/www

Now, go back to the previous page, furnish the details and “WordPress” should happily move ahead. Run the installation

That completes what we tried to achieve. “WordPress” running successfully from a WSL environment.

Now, it is time to ask the questions like “Why so much pain, when we can achieve the entire “WordPress” thing on Windows?”

Well, primarly “WordPress” performs better on Linux enviorment (personal observation), second & most important for me. I just love learning something new everyday. You are welcome!

Microsoft has added WSL with it’s Server 2016 (Version 1803) & the vision is pretty clear. Microsoft “wants” to provide a LINUX environment within Windows so that in the future, a separate LINUX Server requirement will NOT truly hurt the customers. Currently the WSL is NOT equipped with desktops/GUI & Pengwin like initiatives are sure making traction. If my guess will NOT go wrong, soon Windows Servers will be running “Linux” side by side & those Linux Servers are going to be as good as physical/Virtualized. We’ll wait eagerly, together.


Windows | Monitors do not wake up after “long” sleep

Hi guys

Recently I faced similar issues with 2 of my new monitors. Both were Samsung S2Nf350 Slim series LEDs (S22F350 & S24F350) & the issue was same.

After a long sleep/idle time the monitors will not wakeup with a mere keypress or mouse movement. I had to reach to the back of the monitors and press the power on button to awake the monitors!

I had chats with Samsung support & they asked me to take the monitors to nearest workshop as the LEGENDS at 1st level support decided that it was a hardware issue.

Then I decided to go through the user manual & came to an area where it narrated about a feature called “Off Timer”. This MUST be a new feature that is available with new generation LED monitors, helping them to turn off automatically after a pre-set period (default 4 hours)

Turning the feature to OFF state has resolved my weeks long “issues” with the monitor not awakening from a sleep.

May be that’s your solution also.