Virtual Machine profile fail, crash

Talk about code development, features, specific bugs, enhancements, patches, and similar things.
Forum rules
Please keep everything here strictly on-topic.
This board is meant for Pale Moon source code development related subjects only like code snippets, patches, specific bugs, git, the repositories, etc.

This is not for tech support! Please do not post tech support questions in the "Development" board!
Please make sure not to use this board for support questions. Please post issues with specific websites, extensions, etc. in the relevant boards for those topics.

Please keep things on-topic as this forum will be used for reference for Pale Moon development. Expect topics that aren't relevant as such to be moved or deleted.
markfilipak

Virtual Machine profile fail, crash

Unread post by markfilipak » 2017-08-05, 19:41

Hello All, And thanks for helping people.

Running PM in a Linux Mint 18 64-bit virtual machine with Win7 64-bit as host.

I create a 'dummy' profile that resides in the host. The resulting 'profiles.ini' is:

[General]
StartWithLastProfile=0

[Profile0]
Name=default
IsRelative=1
Path=1oyhyp4u.default
Default=1

[Profile1]
Name=dummy
IsRelative=0
Path=/media/sf_Data/browser/dummy

When I attempt to start 'dummy', I get a PM window with 2 tabs. Then PM crashes and must be forced to quit.

Two tabs:

"Pale Moon - Congratulations"

"Start - Pale Moon - start.me"


The "Pale Moon - Congratulations" tab is:
'http://www.palemoon.org/firstrun.shtml', and says:
"The bookmarks and history system will not be functional because on of Pale Moon's files is in use by another application. Some security software can cause this problem. [Learn More]"

The "Start - Pale Moon - start.me" is:
'https://palemoon.start.me/start', and says:
"Oops! Something went wrong. To be sure we advise you to reload the page. [Read more]"

I will hold off further troubleshooting awaiting guidance.

Regards,
Mark.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35576
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Virtual Machine profile fail, crash

Unread post by Moonchild » 2017-08-06, 10:34

Make sure your profile path has the correct permissions so Pale Moon can write to it.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

markfilipak

Re: Virtual Machine profile fail, crash

Unread post by markfilipak » 2017-08-07, 03:13

Howdy MC,
Moonchild wrote:Make sure your profile path has the correct permissions so Pale Moon can write to it.
I can't see anything wrong. Before tackling this, let me ask: Do you know of anyone who is running PM in a Linux VM, but with the profile in the (host's) shared directory?

Scenerio:
Running PM in a Linux Mint guest, hosted by VirtualBox running in a Win7 host.

I've tried creating a profile in the VirtualBox shared directory (folder in Win7 host: 'C:\Data\', mount point in Linux guest: '/media/sf_Data/') as user: mark and as root. Both tries failed. (Note that both succeed when using 'default' profiles).

Details follow.

Launch PM ('palemoon -p') as user: mark.
Create new profile
Credentials = user: 'mark', group: 'vboxsf',
profile: '/media/sf_Data/browser/test' <-- sf_Data is VBox shared directory,
profile name: 'test'

[Start Pale Moon] using 'test' profile.
Result:
Error banner in PM: "The bookmarks and history system will not be functional because one of Pale Moon's files in use by another application. Some security software can cause this problem. [Learn More]"
Clicking [Learn More] results in a 404 (URL: 'http://www.palemoon.org/support/places-locked').

(Note that [Start Pale Moon] as user: mark, using 'default' profile (i.e., '/home/mark/.moonchild productions/pale moon/1oyhyp4u.default') succeeds.)

Launch PM ('palemoon -p') as root.
Create new profile
Credentials = user: 'root'.
profile: '/media/sf_Data/browser/as root' <-- sf_Data is VBox shared directory,
profile name: 'root'

[Start Pale Moon] using 'root' profile.
Result:
Error banner in PM: "The bookmarks and history system will not be functional because one of Pale Moon's files in use by another application. Some security software can cause this problem. [Learn More]"
Clicking [Learn More] results in a 404 (URL: 'http://www.palemoon.org/support/places-locked').

(Note that [Start Pale Moon] as root, using 'default' profile (i.e., '/root/.moonchild productions/pale moon/we909hh5.default') succeeds.)


root terminal session transcript:

Code: Select all

mark-VirtualBox palemoon # palemoon -p
*************************
A coding exception was thrown and uncaught in a Task.

Full message: TypeError: PlacesUtils.history is undefined
Full stack: this.DownloadHistoryObserver@resource://gre/modules/DownloadIntegration.jsm:1004:3
task_DI_initializePublicDownloadList@resource://gre/modules/DownloadIntegration.jsm:263:7
TaskImpl_run@resource://gre/modules/Task.jsm:330:41
Handler.prototype.process@resource://gre/modules/Promise.jsm -> resource://gre/modules/Promise-backend.js:867:23
this.PromiseWalker.walkerLoop@resource://gre/modules/Promise.jsm -> resource://gre/modules/Promise-backend.js:746:7
this.PromiseWalker.scheduleWalkerLoop/<@resource://gre/modules/Promise.jsm -> resource://gre/modules/Promise-backend.js:688:37

*************************
*************************
A coding exception was thrown and uncaught in a Task.

Full message: TypeError: PlacesUtils.history is undefined
Full stack: @resource://gre/modules/PlacesUtils.jsm:1862:5
XPCU_defineLazyGetter/<.get@resource://gre/modules/XPCOMUtils.jsm:193:33
this.PlacesUtils.promiseDBConnection@resource://gre/modules/PlacesUtils.jsm:1233:30
PU_asyncGetBookmarkIds/<@resource://gre/modules/PlacesUtils.jsm:1255:24
TaskImpl_run@resource://gre/modules/Task.jsm:314:40
TaskImpl@resource://gre/modules/Task.jsm:275:3
createAsyncFunction/asyncFunction@resource://gre/modules/Task.jsm:249:14
Task_spawn@resource://gre/modules/Task.jsm:164:12
PU_asyncGetBookmarkIds@resource://gre/modules/PlacesUtils.jsm:1254:5
BUI_updateStarState@chrome://browser/content/browser.js:3210:25
XULBrowserWindow.onLocationChange@chrome://browser/content/browser.js:10329:9
_callProgressListeners/<@chrome://browser/content/tabbrowser.xml:444:24
_callProgressListeners@chrome://browser/content/tabbrowser.xml:441:13
updateCurrentBrowser@chrome://browser/content/tabbrowser.xml:1029:1
onselect@chrome://browser/content/browser.xul:1:44
set_selectedIndex@chrome://global/content/bindings/tabbox.xml:666:13
set_selectedPanel@chrome://global/content/bindings/tabbox.xml:685:13
set_selectedIndex@chrome://global/content/bindings/tabbox.xml:399:15
set_selectedItem@chrome://global/content/bindings/tabbox.xml:431:34
_selectNewTab@chrome://global/content/bindings/tabbox.xml:476:11
onxblmousedown@chrome://global/content/bindings/tabbox.xml:785:11

*************************
*************************
A coding exception was thrown and uncaught in a Task.

Full message: ReferenceError: gAsyncDBConnPromised is not defined
Full stack: this.PlacesUtils.promiseDBConnection@resource://gre/modules/PlacesUtils.jsm:1233:30
PU_asyncGetBookmarkIds/<@resource://gre/modules/PlacesUtils.jsm:1255:24
TaskImpl_run@resource://gre/modules/Task.jsm:314:40
TaskImpl@resource://gre/modules/Task.jsm:275:3
createAsyncFunction/asyncFunction@resource://gre/modules/Task.jsm:249:14
Task_spawn@resource://gre/modules/Task.jsm:164:12
PU_asyncGetBookmarkIds@resource://gre/modules/PlacesUtils.jsm:1254:5
BUI_updateStarState@chrome://browser/content/browser.js:3210:25
XULBrowserWindow.onLocationChange@chrome://browser/content/browser.js:10329:9
_callProgressListeners/<@chrome://browser/content/tabbrowser.xml:444:24
_callProgressListeners@chrome://browser/content/tabbrowser.xml:441:13
updateCurrentBrowser@chrome://browser/content/tabbrowser.xml:1029:1
onselect@chrome://browser/content/browser.xul:1:44
set_selectedIndex@chrome://global/content/bindings/tabbox.xml:666:13
set_selectedPanel@chrome://global/content/bindings/tabbox.xml:685:13
set_selectedIndex@chrome://global/content/bindings/tabbox.xml:399:15
set_selectedItem@chrome://global/content/bindings/tabbox.xml:431:34
_selectNewTab@chrome://global/content/bindings/tabbox.xml:476:11
onxblmousedown@chrome://global/content/bindings/tabbox.xml:785:11

*************************
*************************
A coding exception was thrown and uncaught in a Task.

Full message: ReferenceError: gAsyncDBConnPromised is not defined
Full stack: this.PlacesUtils.promiseDBConnection@resource://gre/modules/PlacesUtils.jsm:1233:30
PU_asyncGetBookmarkIds/<@resource://gre/modules/PlacesUtils.jsm:1255:24
TaskImpl_run@resource://gre/modules/Task.jsm:314:40
TaskImpl@resource://gre/modules/Task.jsm:275:3
createAsyncFunction/asyncFunction@resource://gre/modules/Task.jsm:249:14
Task_spawn@resource://gre/modules/Task.jsm:164:12
PU_asyncGetBookmarkIds@resource://gre/modules/PlacesUtils.jsm:1254:5
BUI_updateStarState@chrome://browser/content/browser.js:3210:25
XULBrowserWindow.onLocationChange@chrome://browser/content/browser.js:10329:9
_callProgressListeners/<@chrome://browser/content/tabbrowser.xml:444:24
_callProgressListeners@chrome://browser/content/tabbrowser.xml:441:13
updateCurrentBrowser@chrome://browser/content/tabbrowser.xml:1029:1
onselect@chrome://browser/content/browser.xul:1:44
set_selectedIndex@chrome://global/content/bindings/tabbox.xml:666:13
set_selectedPanel@chrome://global/content/bindings/tabbox.xml:685:13
set_selectedIndex@chrome://global/content/bindings/tabbox.xml:399:15
set_selectedItem@chrome://global/content/bindings/tabbox.xml:431:34
_selectNewTab@chrome://global/content/bindings/tabbox.xml:476:11
onxblmousedown@chrome://global/content/bindings/tabbox.xml:785:11

*************************
*************************
A coding exception was thrown and uncaught in a Task.

Full message: ReferenceError: gAsyncDBConnPromised is not defined
Full stack: this.PlacesUtils.promiseDBConnection@resource://gre/modules/PlacesUtils.jsm:1233:30
PU_asyncGetBookmarkIds/<@resource://gre/modules/PlacesUtils.jsm:1255:24
TaskImpl_run@resource://gre/modules/Task.jsm:314:40
TaskImpl@resource://gre/modules/Task.jsm:275:3
createAsyncFunction/asyncFunction@resource://gre/modules/Task.jsm:249:14
Task_spawn@resource://gre/modules/Task.jsm:164:12
PU_asyncGetBookmarkIds@resource://gre/modules/PlacesUtils.jsm:1254:5
BUI_updateStarState@chrome://browser/content/browser.js:3210:25
XULBrowserWindow.onLocationChange@chrome://browser/content/browser.js:10329:9
_callProgressListeners/<@chrome://browser/content/tabbrowser.xml:444:24
_callProgressListeners@chrome://browser/content/tabbrowser.xml:441:13
updateCurrentBrowser@chrome://browser/content/tabbrowser.xml:1029:1
onselect@chrome://browser/content/browser.xul:1:44
set_selectedIndex@chrome://global/content/bindings/tabbox.xml:666:13
set_selectedPanel@chrome://global/content/bindings/tabbox.xml:685:13
set_selectedIndex@chrome://global/content/bindings/tabbox.xml:399:15
set_selectedItem@chrome://global/content/bindings/tabbox.xml:431:34
_selectNewTab@chrome://global/content/bindings/tabbox.xml:476:11
onxblmousedown@chrome://global/content/bindings/tabbox.xml:785:11

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35576
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Virtual Machine profile fail, crash

Unread post by Moonchild » 2017-08-07, 08:32

I think your problem depends very much on how these VM "shared host directories" are implemented.
There is no guarantee that browser profiles will work on anything but local paths or mapped drive paths with full write permissions and no spurious file locks (e.g. due to synching operations). UNC paths MAY work but are tricky, and may fail.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

markfilipak

Re: Virtual Machine profile fail, crash

Unread post by markfilipak » 2017-08-08, 16:19

Moonchild wrote:I think your problem depends very much on how these VM "shared host directories" are implemented.
There is no guarantee that browser profiles will work on anything but local paths or mapped drive paths with full write permissions and no spurious file locks (e.g. due to synching operations). UNC paths MAY work but are tricky, and may fail.
True, MC. But I can put my Thunderbird profile in the shared host directory. Why can't I put my PM profile in the shared host directory?

Do you know of anyone who's done it?

[... What's a UNC path? ...]

PS: Are those coding exceptions any clue to you?

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35576
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Virtual Machine profile fail, crash

Unread post by Moonchild » 2017-08-08, 16:37

Thunderbird != Pale Moon. It's not even a browser :P
Just because it's both Mozilla platform doesn't mean it'll behave the same.

a UNC path is \\Server\Path\to\file

The exception is rather generic. It indicates that a required module has not initialized/is not available.
As to why this fails, I can't tell without diving into the code :P
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

markfilipak

Re: Virtual Machine profile fail, crash

Unread post by markfilipak » 2017-08-08, 17:05

Thanks MC,
Moonchild wrote:Thunderbird != Pale Moon. It's not even a browser :P
Just because it's both Mozilla platform doesn't mean it'll behave the same.
Ah, okay.
You should resolve the broken link: 'http://www.palemoon.org/support/places-locked'.
The link is encountered when the '[Learn More]' button is clicked in the Error banner:
"The bookmarks and history system will not be functional because one of Pale Moon's files in use by another application. Some security software can cause this problem. [Learn More]"
Clicking [Learn More] results in a 404 (URL: 'http://www.palemoon.org/support/places-locked').

Regards,
Mark.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35576
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Virtual Machine profile fail, crash

Unread post by Moonchild » 2017-08-10, 11:44

Support page has been written for this, broken link should be resolved.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

markfilipak

Re: Virtual Machine profile fail, crash

Unread post by markfilipak » 2017-08-14, 17:55

Pale Moon is not running.

In order to facilitate a backup regime, I created 2 ping-pong folders:
'/media/sf_Data/browser backup/~ (#1)/' &
'/media/sf_Data/browser backup/~ (#2)/'
in the host shared directory.

I planned to write a script that, on one day copies
'/home/mark/.moonchild productions/*' to
'/media/sf_Data/browser backup/~ (#1)/.moonchild productions/',
and on the next day copies
'/home/mark/.moonchild productions/*' to
'/media/sf_Data/browser backup/~ (#2)/.moonchild productions/',
and so on...

I manually rehearsed the operation to see if there would be any glitches. There were!

STEP #1.

Copy folder
'/home/mark/.moonchild productions/*' to
'/media/sf_Data/browser backup/~ (#1)/.moonchild productions/'.

This produced 1 error:
"There was an error creating the folder '766948556cbtd.'." <-- Illegal Microsoft name (ends with '.')

A search for folder "766948556cbtd." found:
'/home/mark/.moonchild productions/pale moon/1oyhyp4u.default/storage/persistent/https+++www.microsoft.com/idb/766948556cbtd./'

...no big deal, it's an empty directory.

STEP #2.

Again, copy (a 2nd time)
'/home/mark/.moonchild productions/*' to
'/media/sf_Data/browser backup/~ (#1)/.moonchild productions/'

This provoked many ask-skip queries of the sort I've been seeing:
"Error while copying 'profiles.ini'. Error renaming temporary file: Text file busy"
"Error while copying 'mimeTypes.rdf'. Error renaming temporary file: Text file busy"
"Error while copying 'SiteSecurityServiceState.txt'. Error renaming temporary file: Text file busy"
...and so on for many files.

There seems to be a Linux problem overwriting files.
Linux seems to be trying to do a "safe copy" by a process that (I assume) works something like this:

tempFileCreate() ? tempExistCompare() ? overwriteByRenaming() ? void() : askSkip() : handleCompareError() : handleCreateError();
// when 'overwriteByRenaming()' fails, 'askSkip' shows the error to the user.

PM seems to not be the issue, but file locking may be. I could not find a running process that could be the offender (though I did kill several processes while retesting).

This glitch means that I can't write backup files to the host shared directory. Since I can't put the profile in the host shared directory (which gets backed up daily), I can't devise a strategy that's safe.

QUESTION:
Is PM closing everything before exiting?

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35576
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Virtual Machine profile fail, crash

Unread post by Moonchild » 2017-08-14, 18:49

markfilipak wrote:Is PM closing everything before exiting?
Anything that can be closed, yes -- the rest is up to the OS to release once the browser process is terminated. That's out of our control.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

markfilipak

Re: Virtual Machine profile fail, crash

Unread post by markfilipak » 2017-08-14, 19:05

Moonchild wrote:
markfilipak wrote:Is PM closing everything before exiting?
Anything that can be closed, yes...
Unless there's a bug, eh?

Just kidding.

I tried an experiment. I took PM out of auto-launch-on-Linux-startup and restarted Linux. I tried my copy experiment with a pristine Linux (sort of like starting in safe mode) and it again failed. So that eliminates PM as any part of the cause.

If you (or anyone browsing this thread) think of something I could do to make it possible for me to back up my profile, I'd really, really like to know.

Ciao -- Mark.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35576
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Virtual Machine profile fail, crash

Unread post by Moonchild » 2017-08-18, 23:38

Use some kind of cloud sync service, would be my suggestion. You could even use torrentsync or something to bypass remote servers.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

Locked