Monday, October 4, 2021

"EEPC has been corrupted" Error

 My computer one day booted and got this message:

"EEPC has been corrupted"

It did not allow booting into windows 10 or safe mode.

All the posts on the net say mcafee endpoint encryption for PC(EEPC) is the problem because it changed the MBR.

I do not have mcafee installed on the machine at all.


The solution for me was one of 3:

1) update your bios firmware. this helped immediately ! (i had an asus prime 550M-A wifi board but this is relevant to any board)

2) the problem above happened many times for me, some times this solution solved it (without updating the bios) go into the bios and change the CSM (compatibility support mode) boot options from "UEFI and legacy" to "legacy only" (this changes the settings for 640k loading MBR code)

One explanation appears here:

https://www.orduh.com/fix-eepc-has-been-corrupted-error/

basically, the MB BIOS code, the code for loading your HD boot code is contained in a 640K memory area at the end of it assuming the the code that will be loaded from the MRB into the 640k area in memory will be small enough to fit before the bios code. when MBR code is bigger it will overwrite the bios code and display that message.

3) another fix that helped me once (before updating the bios) create a win 10 rescue disk on the usb drive, boot from it and repair the MBR (choose troubleshoot and fix boot problems).

you can create a win 10 rescue usb drive from any other win 10 computer.

Saturday, September 19, 2020

Compiling flip fluids in windows using mingw, cmake and cmd

This worked for me in blender 2.90

3 locations I found useful:

1. a reddit post (see below)

2. the actual README.md that comes with the git sources

3. installation:  zip this folder build\bl_flip_fluids into one zip file and then in blender, edit->preferences->add ons-> install-> double click that file and after that add a checkbox to it and exit preferences


To test that it works: see this video https://www.youtube.com/watch?v=44n3z3g9sVc from 14:20

(the whole video shows compiling with visual studio which is problematic so just go to the location for testing)

REDDIT POST

I found this archived reddit thread that was useful (unfortunately it is archived so couldn't add to it a small correction to make it work in red below - i will copy it here too):

-- credit and thanks to u/Blocks_ --



The above was built from the code on the GitHub repository, which is under the GNU General Public License. This license allows for redistribution. Unfortunately, I cannot provide binaries for MacOS or Linux since I only run Windows. Also, note that the above download is for Blender 64-bit (which should be the default on the blender.org downloads page). The GitHub version also doesn't include the cool materials.

As with anything you find on the internet, make sure you're not downloading anything sketchy. I've left compilation instructions in case you don't trust my pre-built binaries.


Installation instructions
  1. Download the .zip file from the link above.

  2. Go to your Blender addons folder (e.g. C:\Program Files\Blender Foundation\Blender 2.81\2.81\scripts\addons).

  3. There is a folder called flip_fluids_addon inside the .zip file. Drag this folder into Blender's addons folder. Make sure to drag the folder and not the contents!

  4. Start Blender and enable FLIP Fluids. In Blender 2.81, you do Edit->Preferences->Add-ons, then search for FLIP Fluids and check the box. I had to start Blender as an administrator for this step but you might not need to.

  5. Close Blender and start it again. Again, I had to start as admin but you might not need to.

  6. Everything should be good to go!

Compilation instructions

You shouldn't need to compile it yourself if you just want to use FLIP Fluids (I've done that for you), but here are the instructions in case anyone wants them.

  1. git clone the repo or download the .zip from the GitHub repository. If you got the .zip, extract it to somewhere on your computer.

  2. Install Mingw-w64 from the Sourceforge link here. Make sure to select posix threads instead of win32 threads. Also make sure to select the i686 architecture if your Blender is 32-bit, or select x86_64 if your Blender is 64-bit. Take note of your installation directory since it'll be important for the next step.

  3. Add your installation directory's bin folder to your PATH. The default should be something like C:\Program Files (x86)\mingw-w64\i686-8.1.0-posix-dwarf-rt_v6-rev0\bin. Google how to add a folder to PATH if you don't know how to do this step.

  4. Install CMake from here. Make sure to add CMake to the system PATH in the installation setup. It does not matter whether you add it for all users or just the current user, but I would recommend selecting the current user option.

  5. Go to your FLIP Fluids files from step 1.

  6. Create a folder called build and enter it.

  7. Open a Command Prompt/Powershell window in this build folder.

  8. Run the following command in CMD/Powershell: cmake.exe -G "MinGW Makefiles" ..

  9. [Original that didnt work for me: Now run this: cmake.exe --build ] New: change this to "mingw-make"

  10. After the build process has finished, you should see a folder called bl_flip_fluids in the build folder. There should be a flip_fluids_addon folder inside your bl_flip_fluids.

  11. Now follow the Installation instructions section above, but ignore the .zip stuff. The folder you need to drag in Installation instructions step 3 is the flip_fluids_addon that we just built.


Hopefully someone found this useful! Have a great day! <3

Tuesday, September 3, 2019

Oracle 19C Cloud versions ADW & ATP do not support loadjava

Checked and got an official answer directly from the team responsible for this in Oracle - the loadjava tool is not supported in ADW and ATP (the 19C cloud versions of the DB)

Wednesday, December 12, 2018

Eclipse crash: _cairo_operator_bounded_by_source: Assertion `NOT_REACHED' failed

Downloaded Eclipse 2018-09
unpacked it and ran it, it crashed at some point.

I got this error:

org.eclipse.m2e.logback.configuration: The org.eclipse.m2e.logback.configuration bundle was activated before the state location was initialized.  Will retry after the state location is initialized.
***WARNING: SWT requires Cairo 1.9.4 or newer
***WARNING: Detected: 1.8.8
org.eclipse.m2e.logback.configuration: Logback config file: /scratch/ewass/workspace/gitonly/.metadata/.plugins/org.eclipse.m2e.logback.configuration/logback.1.9.1.20180912-1601.xml
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [bundleresource://510.fwk116184677:1/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [bundleresource://510.fwk116184677:2/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [ch.qos.logback.classic.util.ContextSelectorStaticBinder]
org.eclipse.m2e.logback.configuration: Initializing logback
java: cairo-misc.c:380: _cairo_operator_bounded_by_source: Assertion `NOT_REACHED' failed.


Cairo is the graphic lib used by eclipse SWT GTK.
Newer eclipse requires newer Cairo as mentioned above.
The problem is i was using oracle linux 6.6 (2.6.32-504.el6.x86_64) - the new cairo is not supported on this OS.

So it seems i have to go back and use and older eclipse (like neon).

Saturday, November 17, 2018

Amazon AWS EC2 - solution to windows update doesn't work

Don't know if it is related specifically to EC2 but anyway i had a windows 2012 server that refused to update when i told it to be automatic or tried to initiate it from the windows update UI.

In the event log i got this message:
"Unable to Connect: Windows is unable to connect to the automatic updates service and therefore cannot download and install updates according to the set schedule. Windows will continue to try to establish a connection."

The solution was to run it manually by this command line:

wuauclt.exe /updatenow


Another tip: if you are running a cheap low mem instance (e.g. t2.nano), restart your server as something stronger (e.g. t2.xlarge) and do all your windows updates from there and when done go back to the cheap instance. much faster and more reliable this way and the small amount of time used in the expensive instance is really low.

Saturday, July 1, 2017

Getting still image URL/URI of an ipcam OR just how to query onvif ip cameras

The net is full of to much TLDR info about ipcams...
Here is a short tutorial on running ONVIF queries to your ipcam to check which URLs do what.

ONVIF is a universal spec that tries to unify function calls to all supported ip cameras.
The problem is ONVIF organization is really the type of "we like to document a lot but not give short examples on how to use" type of org (maybe they should start thinking in the direction of open sourcing and supporting sites that try to explain their specs instead of hunting them down for posting a spec that is hidden in their own "membership" areas on their site)

So here is the short "Hello World" on ONVIF and ipcams:

Lets go through a learning experience - i have a cheap ali express ip cam and i want to figure out which cam URLs are used for streaming video and which cam URLs can give me a still image.

I want this because i want to port forward these specific ports and be able to access them directly and not via some P2P Chinese service app that wants all permissions on my android...(RTSP streaming video can be opened on many standard android apps and on vlc)

STEPS:

1. Connect

Physically connect the cam to the router on your home LAN using an ethernet cable - fairly easy
Note that there are wifi ipcams and ethernet ipcams - both have an option to connect an ethernet cable
The good ones will be pre-configured to get an IP from DHCP
The bad ones will have some preconfigured ip address, but they can be changed to DHCP, you just need to connect to their http address and change it (wait but i don't know their IP ....?! - try changing your router to 10.0.0.X subnet or 192.168.1.X subnet and connecting just a computer and your cam, then see next section on how to find them)

2. Discover ip/port 

Lets find the ip and port of the ONVIF service on the cam -
First, how to check i found the correct ip and port-
just enter in your browser and see a SOAP response like this:
for example enter: http://192.168.14.41:8899/

and get:

SOAP-ENV:ClientHTTP GET method not implemented

that means we found it (never mind about the error - we will see about that later)

So how to find the ip/port:
option A: if you know how to enter your router's http and check connected clients you can do that to find the IP, then you will have to scan that ip or try some well known ONVIF ports (e.g. 8899/1018)

option B: install "Fing" on your android cellphone - it will scan your local net and find it. again you will need to find the correct port

option C: install "Onvif device manager" or "iSpy" on your windows machine - they will scan your net and ports and find the ipcams and their onvif ports for you

3. Lets talk Onvif language with our cam-

Onvif speaks SOAP protocol - we will need a browser add-on to make life easier for us because we are too lazy to program stuff (or write long command lines with 'curl') -

In firefox, go to add-ons and click extensions, and add "RESTClient" extension +restart firefox.
Lets start by telling the device we want some general information -
lets assume my ip/port are 192.168.14.51:8899

Click on the RESTClient red rectangular button on the top of the browser and you will get this screen:


When you enter a URL in the browser address bar it uses http GET protocol. SOAP uses http POST protocol, which besides the URL has a "BODY" part too - so  we will use the add-on to sent the POST commands (this can be done in linux/windows command line using "curl" too).

change the "Method" to POST
in the URL put http://192.168.14.51:8899
in the BODY put:

<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://www.w3.org/2003/05/soap-envelope"
 xmlns:tds="http://www.onvif.org/ver10/device/wsdl">
<SOAP-ENV:Body>
    <tds:GetDeviceInformation/>
  </SOAP-ENV:Body>
</SOAP-ENV:Envelope>


 


click "SEND"

on the bottom part in "Response" change the tab to "Response Body (highlight)"
skip all the bloated SOAP-ENV xml shit, and in the bottom you will see something like:

<SOAP-ENV:Body>
 <tds:GetDeviceInformationResponse>
   <tds:Manufacturer>H264</tds:Manufacturer>
   <tds:Model>50H20L_S39</tds:Model>
   <tds:FirmwareVersion>V4.02.R11.00002520.10010.242900.ONVIF 2.4</tds:FirmwareVersion>
   <tds:SerialNumber>1b011f97f22424de</tds:SerialNumber>
   <tds:HardwareId>00001</tds:HardwareId>
 </tds:GetDeviceInformationResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>



Great ! it works ! (if not, then your ip/port are not correct or your ip camera 
does not support onvif)

4. Check video stream URLs

everything same as before just change the body:


<?xml version="1.0" encoding="UTF-8"?>
<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope"
xmlns:trt="http://www.onvif.org/ver10/media/wsdl">
   <soap:Body>
      <trt:GetProfiles/>
   </soap:Body>
</soap:Envelope>

  
    

click SEND

as usual, skip all the soap shit and got to the bottom of the response (in the response body tab not response headers tab!)

you will get a list a profiles with their tokens and resolutions etc...:

<SOAP-ENV:Body>
 <trt:GetProfilesResponse>
   <trt:Profiles fixed="true" token="000">
     <tt:Name>Profile_000</tt:Name>
     <tt:VideoSourceConfiguration token="000">
       <tt:Name>VideoS_000</tt:Name>
       <tt:UseCount>3</tt:UseCount>
       <tt:SourceToken>000</tt:SourceToken>
       <tt:Bounds height="1080" width="1920" y="0" x="0">
       </tt:Bounds>
     </tt:VideoSourceConfiguration>
     <tt:AudioSourceConfiguration token="000">
       <tt:Name>Audio_000</tt:Name>
       <tt:UseCount>2</tt:UseCount>
       <tt:SourceToken>000</tt:SourceToken>
     </tt:AudioSourceConfiguration>
     <tt:VideoEncoderConfiguration token="000">
       <tt:Name>VideoE_000</tt:Name>
       <tt:UseCount>1</tt:UseCount>
       <tt:Encoding>H264</tt:Encoding>
       <tt:Resolution>
         <tt:Width>1920</tt:Width>
         <tt:Height>1080</tt:Height>
       </tt:Resolution>
       <tt:Quality>4</tt:Quality>

:
<----cut ----="" here="" response="">

now lets get the URL of a specific profile token ("000"). Send this body:
 
<?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:trt="http://www.onvif.org/ver10/media/wsdl" xmlns:tt="http://www.onvif.org/ver10/schema"> <soap:Body> <trt:GetStreamUri> <trt:StreamSetup> <tt:Stream>RTP-Unicast</tt:Stream> <tt:Transport> <tt:Protocol>UDP</tt:Protocol> </Transport> </trt:StreamSetup> <trt:ProfileToken>000</trt:ProfileToken> </trt:GetStreamUri> </soap:Body> </soap:Envelope>

and you get this kind of response containing the URL:
<SOAP-ENV:Body>
  <trt:GetStreamUriResponse>
    <trt:MediaUri>
      <tt:Uri>rtsp://192.168.14.51:554/user=admin_password=1234_channel=1_stream=0.sdp?real_stream</tt:Uri>
      <tt:InvalidAfterConnect>false</tt:InvalidAfterConnect>
      <tt:InvalidAfterReboot>false</tt:InvalidAfterReboot>
      <tt:Timeout>PT10S</tt:Timeout>
    </trt:MediaUri>
  </trt:GetStreamUriResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>



lets test it:
open it (rtsp://192.168.14.51:554/user=admin_password=1234_channel=1_stream=0.sdp?real_stream)
in VLC (window/android) or some other RTSP Player (i like android VXG RTSP player)
it should show the live stream
(note vlc tends to crash some times. try a different app or VLC beta if this happens)

5. check still image (jpg) URL

send this body (update the profile token id to yours):
 
<?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" xmlns:trt="http://www.onvif.org/ver10/media/wsdl" xmlns:tt="http://www.onvif.org/ver10/schema"> <soap:Body> <trt:GetSnapshotUri > <trt:ProfileToken>000</trt:ProfileToken> </trt:GetSnapshotUri> </soap:Body> </soap:Envelope>

you should get something like:

<SOAP-ENV:Body>
 <trt:GetSnapshotUriResponse>
   <trt:MediaUri>
     <tt:Uri>http://192.168.14.51/webcapture.jpg?command=snap&amp;channel=1</tt:Uri>
     <tt:InvalidAfterConnect>false</tt:InvalidAfterConnect>
     <tt:InvalidAfterReboot>false</tt:InvalidAfterReboot>
     <tt:Timeout>PT10S</tt:Timeout>
   </trt:MediaUri>
 </trt:GetSnapshotUriResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>





Paste the URL in the browser URL section it check if it works ... :)

6. Other cool stuff you can do with onvif

There are a lot of things you can do with onvif
A spec PDF can be found here:
http://www.openipcam.com/files/ONVIF/ONVIF_WG-APG-Application_Programmer's_Guide.pdf
(openipcam is a great resource site)
skip directly to "appendix B2" with the SOAP examples.
I am sure you will manage from there ...


7. Security

You ip cam is a basically a linux box. lately too many ip cams have been 
victims of hosting malware/botnet/viruses.

These cams can easily hide a program waiting for a C&C server to tell them to start blasting 
an IP with denial of service packets or just be used as proxy for hacking activities.

I recommend - reserve your ip cam a dedicated ip in your router or just assign it a 
static ip + set firewall rules in your router not to let any packet in/out (especially out)
if it is not on the port you are using.

Also change the defaul user/passwords

Also - from time to time bring up wireshark on your localnet and just look at the traffic.



 

Tuesday, May 31, 2016

Weblogic process list (ps) with weblogic server names

Many times when using weblogic you want to kill specific weblogic servers.
When you run ps, you get a huge blurb of data in the weblogic process lines.
Even if you use 'jps' (java ps) it will give a much shorter list but it will lack the weblogic server names that correspond to the processes.

here is a command that can be run and will give exactly what we want:

    ps -aef | grep javaee | grep Dweblogic.Name | sed -e 's/\-Dweblogic\.Name/WLPROC/g' -e 's/\-[^ ]*\s//g' -e 's/\/[^ ]*\s//g'

Here is an example output:
userX    10611 10608  5 05:34 pts   00:03:13 WLPROC=AnalyticProviderServices0 weblogic.Server
userX    20918 20915  0 May26 pts   00:18:28 WLPROC=AdminServer weblogic.Server