Tag Archives: service

[Solved] Startservice error: Process: com.example.provider, PID: 31612

Error Messages:

Process: com.example.provider, PID: 31612
    java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.provider/com.example.provider.MainActivity}: java.lang.IllegalStateException: Not allowed to start service Intent { cmp=com.example.provider/.MyService }: app is in background uid UidRecord{9c06385 u0a69 TPSL idle change:idle|cached procs:1 seq(0,0,0)}
        at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3270)
        at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3409)
        at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:83)
        at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
        at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2016)
        at android.os.Handler.dispatchMessage(Handler.java:107)
        at android.os.Looper.loop(Looper.java:214)
        at android.app.ActivityThread.main(ActivityThread.java:7356)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:930)
     Caused by: java.lang.IllegalStateException: Not allowed to start service Intent { cmp=com.example.provider/.MyService }: app is in background uid UidRecord{9c06385 u0a69 TPSL idle change:idle|cached procs:1 seq(0,0,0)}
        at android.app.ContextImpl.startServiceCommon(ContextImpl.java:1616)
        at android.app.ContextImpl.startService(ContextImpl.java:1571)
        at android.content.ContextWrapper.startService(ContextWrapper.java:669)
        at android.content.ContextWrapper.startService(ContextWrapper.java:669)
        at com.example.provider.MainActivity.onCreate(MainActivity.java:15)
        at android.app.Activity.performCreate(Activity.java:7817)
        at android.app.Activity.performCreate(Activity.java:7806)
        at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1306)
        at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3245)

 

Solution:

After Android 8.0, background processes are no longer allowed to start services directly through the startService method.:

startForegroundService

[Solved] Android Error: java.lang.IllegalStateException: Not allowed to start service Intent

Android error: java.lang.illegalstateexception: not allowed to start service intent

Error resolution 12

Today’s test threw me a crash message:

Caused by: java.lang.IllegalStateException: Not allowed to start service Intent { cmp=xxx }: app is in background uid UidRecord{xxx u0a136 CEM idle procs:1 seq(0,0,0)}

Can it be hard for me
once you see it, you can see that it’s a background service startup error. Just put the service in the foreground, easy

In fact, Google took a look
https://stackoverflow.com/questions/46445265/android-8-0-java-lang-illegalstateexception-not-allowed-to-start-service-inten
The problem is that Android 8.0 does not allow the creation of background services.

Solution:

Method 1:

The simplest way is to directly open the front desk service
set the service to the front desk in oncreate of your service class

if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
       startForeground(1, new Notification()); 
}

Of course, this method will show what is running on the status bar of Android 5.0 and 6.0 phones please refer to the following method

Method 2:

The method from here

first modify the service configuration in your manifest file

<service android:name=".YourService"
         android:permission="android.permission.BIND_JOB_SERVICE"/>

Then change the modification inheritance of your service class to extensions jobintentservice
and add the following code

    public static final int JOB_ID = 1;

    public static void enqueueWork(Context context, Intent work) {
        enqueueWork(context, YourService.class, JOB_ID, work);
    }

    @Override
    protected void onHandleWork(@NonNull Intent intent) {
        // your code
    }

The startup service is modified as follows.

YourService.enqueueWork(context, new Intent());

However, I tested that the content in onstartcommand() does not execute. No reason has been found
I hope you can help me with the analysis.

It’s over

Appium step pit summary — solution

1. There are appium command version and appium desktop version in the computer, After opening appium desktop version, the script will run with an error:
selenium.common.exceptions.webdriverexception: Message: an unknown server-side error occurred while processing the command. Original error: cannot start the ‘com. XXXX’ application.
main meaning: an unknown server-side error occurred while processing the command

Check:
I found that the command line version (1.20.2) is inconsistent with the desktop version (1.14.1), appium – V, view version

Solution:
close the desktop version, enter appium in the CMD to execute the command line version, execute the script, and it can run successfully
solution 2: upgrade the desktop appium version or reduce the appium command line version

Error: not found; no service started

Sometimes it’s a headache to report an error. If you have a problem with your own code, you can still solve it. However, if there is a problem with the as tool, it’s embarrassing!
I’ve heard that as2.3 has its own bug before, but I haven’t encountered it. Fortunately, I did today! All kinds of search information, over the wall!
The error is as follows:

Starting service: Intent 
{ act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] 
cmp=com.xxx.xxx.constrain/com.android.tools.fd.runtime.InstantRunService }
Error: Not found; no service started.

Solution:
first, simply and crudely re install as2.3 (I use version 2.3)
Second, upgrade as in the case of upgrade. At present, my as is upgraded from 2.3 to 2.3.1
and above, and all the problems can be solved

Net start command system error 5 and error 1058 solution

Source: http://blog.csdn.net/u012586848/article/details/46860839

1. Net start command

The net start command is used to start the service in the form of net start [service name] (the corresponding “net stop [service name]” is the command to close the service)

2. Open the default instance service of sqlserver

[win + R] shortcut – & gt; CMD – & gt; net start MSSqlServer

Prompt error “system error 5 occurred”, the screenshot is as follows:

3. Error analysis

The reason for this error is that there is a difference between the administrator and non administrator permissions in win7/win8 command prompt, and the net stat command can only be run under the administrator permission.

4. Solutions

1) Open the command prompt with administrator’s permission: [start] — & gt; search for “CMD” — & gt; right click “run as administrator”, or use the shortcut key [win + X + a]

2) Enter “net start MSSqlServer” successfully. The screenshot is as follows:

note appended:

The above method can solve the “system error 5 access denied” error of the “net start” command, but it may still not be able to open the corresponding service, prompting “error 1058”, as shown in the figure below:

As shown in the error prompt in the figure, the reason may be that MS SQL server has been disabled or its associated device has not been started. For MSSqlServer service, find the “MSSqlServer” service in control panel — & gt; management tools — & gt; services, double-click to open properties, and select the dependency tab to see that the service has “no dependency”. Therefore, the reason of “other associated devices are not started” is excluded, as shown in the following figure

Switch the properties window to the General tab, and you can see that the service status is “stopped” and the start type is “disabled”. Change the start type to one of the other three items besides “disabled” – & gt; [OK].

Reference source:

one http://answers.microsoft.com/zh-hans/windows/forum/windows8_ 1-performance/%E8%BF%90%E8%A1%8Cnet-start/bec244e5-6385-4950-adc8-0d004905e41a?auth=1

two http://www.2cto.com/database/201304/200600.html

How do I download or save a YouTube video to my computer?

Getting the YouTube file to your computer
Today, there are several online websites that allow you to enter the URL of the video you wish to save to your computer, and get a link to download the file. Below is a short list of some of the more popular free websites.
http://www.savevid.com/
http://keepvid.com/
Below is a brief description of how to save a video using Savevid. These steps are often very similar with other services used to save YouTube and other flash videos online.

    Go to the YouTube video page and copy the URL of the video you wish to save. For example, below is a URL to a video on YouTube.

    http://www.youtube.com/watch?v=R3ymHMgFAps
     Once this address has been copied, visit SaveVid and paste that URL into the URL text field, then click the Submit or Download button. If done properly, the page should open a new window or display a link to each of the video formats that can be saved. Savevid will give you the option to save the video as FLV, 3GP, MP4 and WebM format. If you’re wanting to watch this video on the computer we recommend saving the video as MP4 format.

Watching a FLV video on your computer
Once the .flv file has been downloaded to your computer, you’ll need a player that supports .flv files. Below are a few suggestions.
VLC media player
http://www.videolan.org/
FLV Player
http://www.martijndevisser.com/blog/flv-player/
Windows Media Player
Microsoft Windows users also have the ability of playing FLV files in Windows Media player with the right codec. Downloading and installing the CCCP codec will install this codec, as well as many other codecs you’ll likely need in the future.
Converting the YouTube video to a different movie format
There are dozens of different software programs and online services available that will allow you to convert FLV files into another format. Below is a short listing of some of the free services and products we recommend.
Media Convert – An excellent online service that can convert FLV files into dozens of other formats.
http://www.media-convert.com/
Vixy – Another great online service that allows you to download and save YouTube video files to another format.
http://vixy.net/

Event ID 407, 408 – when NAT is used as a DNS server

QUESTION NO: 211

You are the administrator of TestKing’s network, which consists of a single Windows 2000 Domain. The

relevant portion of its configuration is shown in the exhibit.

You configure a Windows 2000 Server computer named NAT1 as the DNS server for the domain. You

install Routing and Remote Access on NAT1. You configure NAT1 to provide network address

translation services for client computers to access the Internet.

Users now report that they cannot log on to the domain or access network resources. On investigation,

you discover that you cannot query NAT1 for name resolution. In the application event log on NAT1, you

find the following event messages:

Event ID: 407

Source: DNS

Description: DNS server could not bind a datagram (UDP) socket to

192.168.0.1. The data is the error.

Event ID: 408

Source: DNS

Description: DNS server could not open socket for address 192.168.0.1.

Verify that this is a valid IP address on this machine.

How should you correct this problem?

A. Disable the DNS proxy functionality on NAT1

B. Enable the DNS proxy functionality on NAT1

C. Reconfigure the DNS server service not to listen on the internal address of NAT1.

D. Reconfigure the DNS server service not to listen on the external address of NAT1.

Answer: C

Explanation: This problem can occur when you have a NAT server that also is used as a DNS server. NAT has

a DNS Proxy setting that enables DHCP clients to direct DNS queries to the NAT server. The client DNS

queries are then forwarded to the NAT server’s configured DNS server. The DNS Proxy and the DNS Server

service cannot coexist on the same host, if the host is using the same interface and IP address with the default

settings.

There are three methods to overcome this problem:

1. Reconfigure the DNS server service not to listen on the internal address. This is the solution in this scenario.

2. Install NAT and DNS on different servers. We cannot change this configuration here since this option is not

listed.

3. Use the DHCP server Service in NAT, NOT the DHCP Allocator and DNS Proxy.

Reference: JSI Tip 3284, Your DNS Event Log reports Event Ids 407 and 408

Incorrect Answers:

A: We could disable both the DNS proxy functionality and the DHCP allocator.

B: The DNS proxy function on the NAT server is partly to blame. Enabling it will not help.

D: We must configure the DNS server not to listen to the internal address, not the external address.

Error 711: Cannot load Remote Access Service Connection Manager.

When you try to create a new network Connection, you may receive the following Error message:
Error 711: Cannot load Remote Access Service Connection Manager.
The Routing and Remote Access service terminated with service-specific error 711 (0x2C7)
Incoming Connections depend on the Routing and Remote Access service which was unable to start.For more information, check the system event log.
The first method:
 
Please take a look at your following services:
Service name: EventLog Display name: Windows Event Log Boot type: Auto
Service Name :TapiSrv Display name: Telephony Startup Type: Manual
Secure Socket Tunneling Protocol Service Startup Type: Manual
Service name :Netman Display name: Network Connections Startup Type: Manual
Service Name: NSI Display name: Network Store Inte*** CE Service Startup Type: Automatic
Service name :RasMan Display name: Remote Access Connection Manager Startup Type: Manual

error :711 friends, I think your service Settings should be on the first service I listed
First service description: This service manages events and event logs. It supports logging events, querying events, subscribing to events, archiving event logs, and managing event metadata. It displays events in BOTH XML and plain text formats. Stopping the service may compromise the security and reliability of the system.
Disabling the first Service will cause the SstpSvc to display the name: Secure Socket Tunneling Protocol Service which stops automatically after startup
And the service name :RasMan shows the name: Remote Access Connection Manager and the service needs to rely on it,
 
 

the second method:

this problem is easy to solve! At the command line run as administrator. Type Netsh WinSock Reset Enter and restart
 
 

the third method:

find C:/Windows/System32/LogFiles/WMI this folder, as long as this folder administrator title and then restart! Use rubik’s cube in the system Settings right menu management inside the new “access to administrator rights” function, and then you can click the right mouse button on the folder above, the administrator to obtain the ownership can be solved.
 

the fourth way :(this method did not try, it must work, but do not want to shut down every time to execute, feel like trying to steal the bell.

see by the members asked — — — — — — — the C:/Windows/System32/LogFiles/WMI right to this folder.
after restart, can be normal broadband connection. Then restart is such a problem, had to go to get the administrator rights of that file again, so after the restart can be on
The old restart is really very annoying, tell you a soil method, although soil, but it is really convenient, do not have to always take permission, restart. It’s the same thing, just write a script and have it run automatically when it’s turned off. Method is as follows:
1, to save the code below. Bat format (name myself to marry a good, I set it to 711. The bat) where is not easy to remove, code for @ ECHO OFF
takeown/f “C:/Windows/System32/LogFiles/WMI” y/r/d & amp; & icacls “C:/Windows/System32/LogFiles/WMI” /grant administrators:F /t
Encourage people to do it themselves, to enrich their food and clothing. The lazy ones or the ones that won’t save can be downloaded for a few bucks and the attachments below are already written

2, click “start” and “run”, in the run command box input “gpedit.msc”, open the group policy window pane on the left side of the console tree, in turn, a “computer configuration” “Windows Settings” “script startup/shutdown” node as shown in figure, double-click the details pane on the right side of the “shutdown” project, in the “shutdown properties” dialog box, click on the “add” button, will 711. Add bat for the new computer shutdown scripts set up complete, exit the group policy window, restart the computer
 
 
Fifth:
After the completion of the installation of Windows7, found that the dial-up connection can not be set up, either 711 error, 1068 dependent service can not start, or 691 error, and so on, it can be said that the error messages are varied!
There is no way, had to install back to WindowsXP, and then search the Internet for reasons, only to find that there are many friends appear the same error, after the search and analysis of the online information, as well as download ready to use the software, again installed back to Windows7.
Try to use the information on the Internet to solve the problem, make late at night, found still wrong, unable to restart to see first, no sleep, ready to install WindowsXp again the next day, a restart, surprise, to be able to connect to the Internet, web pages can be opened normally, success!
It’s two o ‘clock in the night. I’m going to bed

through several hours of groping, successfully dial-up Internet!
now put possible solutions, write out to share, may not be able to solve all the friends of the problem, but can try!
1,
install Windows7, then open control panel open network and Internet open view network status and tasks, select set up new connection or network, according to your network type set up the connection, set up the same method as WindowsXp.
 

“computer — management — services and applications — services”, go to the “Remote Access Connection Manager”, and check whether the “boot type” is “automatic”, if not, change to “automatic”. Similarly, find “Internet Connection Sharing (ICS)” and set it to “Auto.” Download ratio
Three,

find “c:/Windows/system32/logfiles” this folder and open.
Select and right-click the “WMI” folder. Select Get Administrator Privileges.

restart the computer!

5,
click on the lower right corner “”,

click the “broadband connection” and “” buttons. Icon “” becomes” “, OK!
open the network and share center, use the netcom broadband conversion tool to convert the user name, copy and paste, enter the password is ok. It’s ok to change the computer name. Right – click computer. Click properties. Click on advanced System Settings. Click computer name again. Click Change. Reset the top computer name in English or letters. Restart your computer. Log in and reconnect.
 
 
 

above five (except for the fourth) can not completely solve the “711 problem”, not necessarily which restart after the error.

here to do a survey, after all, recently there are many friends with this problem, everyone say
Because of what reason does oneself appear this problem?Is this the new system?Or after changing something?)
Is there a radical solution??(except for reinstall and system restore)
Hope to be able to solve this problem thoroughly through this post for the friends who are worried about this problem!

Error 1045 (28000): solution to access denied for user ‘root’ @’localhost ‘(using password: no)


This problem was encountered when installing MySQL service under Windows, which was installed with MySQL green version. After installation, when connecting to MySQL service, enter the command “mysql-uroot-p”. Because the password was not set for the first login, the error message was as follows:
“ERROR 1045 (28000): Access Denied for user ‘root’@’localhost’ (using password: NO)”

The diagram below:

Solutions:
First you need to turn off the MySQL service and enter the command:
mysql> net stop MySQL
To start the local MySQL service in safe mode (note: launch the CMD window as an administrator), enter the command “MySQld — Defaults file=”G:\Install_Applications\ mysql.8.0.11 \ My.ini” –console –skip-grant — tables “to start the MySQL service, the cursor will stop without any output, which indicates that the MySQL service has been started.

Start the CMD window, and enter the command “mysql-uroot-p” to directly enter and log in to the mysql server, and then modify, you can enter the command:
(before 5.7.11) & GT; update user set password=password(“123456″) where user=”root”;

(5.7.11 or later) & GT; update user set authentication_string=password(“123456″) where user=”root”;
Here I’m using:
mysql> ALTER USER ‘root’@’localhost’ IDENTIFIED BY ‘HuaZai12345! ‘;
The diagram below:

Now exit, enter the command “mysql-uroot-p” and enter the password just set, and you can log in to the mysql server normally, as shown in the figure below:

Ok, this is the solution for ERROR 1045 (28000): Access Denied for user ‘root’@’localhost’ (using password: NO). If you have any questions, please feel free to leave me a message.

: “learn together, make progress together”, I also hope that we will pay more attention to the IT community of CSND.

About the cause of the long-standing ADO error: unspecified error “(error code = 0x80004005) (excerpt from the Internet)

ms-help://MS.MSDNQTR.2005APR.1033/enu_kboledb/oledb/251254.htm
SYMPTOMS
When trying to connect to an Access .mdb file, an ODBC error is returned stating “Disk or Network Error”. The Microsoft OLE DB Provider for the Microsoft Jet database engine may also return an “Unspecified error” (error code = 0x80004005) message.

The problem can occur only when the data source is opened under the Microsoft Internet Information Server (IIS) or a Microsoft Windows NT service but not under a logged-on user account.
CAUSE
Jet creates a temporary file when the engine is started. In doing so, it first checks the TMP environment variable and uses that path to define where the temporary file is created. If it doesn’t see a TMP environment variable, it looks for the TEMP environment variable. If TEMP is not defined, it then uses the Windows folder (/WINDOWS or /WINNT).

If TMP/TEMP is defined but points to a nonexistent folder, the error occurs.

Moreover, when opening the Access database through IIS or a Windows NT service, and when IIS or the service is running under the local system account, the TMP or TEMP system environment variable is used. When the Web services or Windows NT service are started using a user account, the TMP/TEMP user profile environment variables is used.
 
RESOLUTION
Define a TMP or TEMP environment variable and assign the variable to an existing folder. If you are accessing the Access database from IIS, be certain to check the system environment settings rather than environment variables of the logged-on user. Also ensure that the IUSER anonymous IIS account has access to the temporary folder.

You must restart the computer after changing any environment variables.
Environment variables are set under Windows NT 4.0 by going to the Control Panel and clicking System and then selecting the Environment tab.

Solve the problem that Windows 7 cannot be updated automatically_ Prompt error code 80246008

Windows 7 cannot automatically update the error code 80246008
Since yesterday, Windows Update Update encountered an error, unable to download and install the Update patch, error code 80246008.
As shown in figure

= = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
Click “Get Help information about the error” in the figure to get the following:
You must log in as an administrator to perform these steps.
If you receive a Windows Update error 80246008 while downloading the Update, you may need to change the backend Smart Transfer Service (BITS) or Windows Event log service Settings, and then restart each service.
The steps to change or restart the backend intelligent Transport Service (BITS)

1.
By clicking the Start button


, then click Control Panel to open Administration Tools. In the search box, type Administrative Tools, and then click Administrative Tools.

2.
Double-click Services.

The apple mobile device service failed to start. Error 1053 is resolved

This article is reproduced from:
https://www.cnblogs.com/relax/p/3476741.html author: relax reprint please indicate the statement.

I didn’t want to install iTunes, so I downloaded the iTunes64 installation package and unzipped it to get six files

Installed AppleMobileDeviceSupport64. Msi found start up service, prompt error 1053, under the search on the net, found the mistake very much

Then continue to install AppleApplicationSupport. Msi, installation is complete to start the Apple Mobile Device service

So Apple Mobile Device service start failure can try to reinstall AppleApplicationSupport. Msi to solve
I shall be very glad if this article is of any help to you