Cannot start mpd as systemd service

Hi all,
I have installed mpd. If I run
mpd
from a terminal, then everything is normal; I can open
a client and use mpd. However, if I try to start it as a systemd service I get errors. That is, once I do
sudo systemctl enable mpd
and reboot, then
jorge@flamingo:~$ systemctl status mpd
● mpd.service - Music Player Daemon
Loaded: loaded (/usr/lib/systemd/system/mpd.service; enabled)
Active: failed (Result: signal) since Thu 2014-09-25 22:01:48 EDT; 2min 20s ago
Main PID: 1647 (code=killed, signal=ABRT)
Sep 25 22:01:48 flamingo mpd[1647]: ALSA lib confmisc.c:1251:(snd_func_refer) error evaluating name
Sep 25 22:01:48 flamingo mpd[1647]: ALSA lib conf.c:4259:(_snd_config_evaluate) function snd_func_refer returned erro...rectory
Sep 25 22:01:48 flamingo mpd[1647]: ALSA lib conf.c:4738:(snd_config_expand) Evaluate error: No such file or directory
Sep 25 22:01:48 flamingo mpd[1647]: ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM default
Sep 25 22:01:48 flamingo mpd[1647]: alsa_output: Error opening default ALSA device: No such file or directory
Sep 25 22:01:48 flamingo mpd[1647]: output: Attempting to detect a oss audio device
Sep 25 22:01:48 flamingo mpd[1647]: oss_output: Error opening OSS device "/dev/dsp": No such file or directory
Sep 25 22:01:48 flamingo mpd[1647]: oss_output: Error opening OSS device "/dev/sound/dsp": No such file or directory
Sep 25 22:01:48 flamingo mpd[1647]: output: Attempting to detect a pulse audio device
Sep 25 22:01:48 flamingo mpd[1647]: Assertion 'm' failed at pulse/thread-mainloop.c:236, function pa_threaded_mainloo...orting.
Hint: Some lines were ellipsized, use -l to show in full.
or,
jorge@flamingo:~$ sudo systemctl start mpd
[sudo] password for jorge:
jorge@flamingo:~$ systemctl status mpd
● mpd.service - Music Player Daemon
Loaded: loaded (/usr/lib/systemd/system/mpd.service; enabled)
Active: failed (Result: signal) since Thu 2014-09-25 22:09:13 EDT; 8s ago
Process: 2056 ExecStart=/usr/bin/mpd --no-daemon (code=killed, signal=ABRT)
Main PID: 2056 (code=killed, signal=ABRT)
Sep 25 22:09:13 flamingo mpd[2056]: ALSA lib confmisc.c:1251:(snd_func_refer) error evaluating name
Sep 25 22:09:13 flamingo mpd[2056]: ALSA lib conf.c:4259:(_snd_config_evaluate) function snd_func_refer returned erro...rectory
Sep 25 22:09:13 flamingo mpd[2056]: ALSA lib conf.c:4738:(snd_config_expand) Evaluate error: No such file or directory
Sep 25 22:09:13 flamingo mpd[2056]: ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM default
Sep 25 22:09:13 flamingo mpd[2056]: alsa_output: Error opening default ALSA device: No such file or directory
Sep 25 22:09:13 flamingo mpd[2056]: output: Attempting to detect a oss audio device
Sep 25 22:09:13 flamingo mpd[2056]: oss_output: Error opening OSS device "/dev/dsp": No such file or directory
Sep 25 22:09:13 flamingo mpd[2056]: oss_output: Error opening OSS device "/dev/sound/dsp": No such file or directory
Sep 25 22:09:13 flamingo mpd[2056]: output: Attempting to detect a pulse audio device
Sep 25 22:09:13 flamingo mpd[2056]: Assertion 'm' failed at pulse/thread-mainloop.c:236, function pa_threaded_mainloo...orting.
Hint: Some lines were ellipsized, use -l to show in full.
Here is the mpd config file:
jorge@flamingo:~$ cat ~/.mpd/mpd.conf
music_directory "/home/jorge/Multimedia/Audio/Music"
playlist_directory "/home/jorge/.mpd/playlists"
db_file "~/.mpd/mpd.db"
log_file "~/.mpd/mpd.log"
pid_file "~/.mpd/mpd.pid"
state_file "~/.mpd/mpdstate"
audio_output {
type "alsa"
name "MPD"
restore_paused "yes"
follow_inside_symlinks "no"
Any ideas what I'm doing wrong here?
Thanks in advance.
Last edited by geo909 (2014-09-26 02:12:30)

Scimmia wrote:Yeah, you're out of date. Update your system and everything should work.
*facepalm*
Oh dear.. An update fixed the problem indeed, thank you.
HilmTye wrote: if you're starting mpd as a system service, then your user's config won't be used
You're right.. I just read the wiki more carefully. Indeed, I would like to run it for my user, so systemd is not
the best option for me. But I still have trouble.. The problem is that I can't autostart it the way it mentions
in the wiki. My mpd files are as follows:
jorge@flamingo:~$ ls ~/.mpd
mpd.conf mpd.db mpd.log mpd.pid mpdstate playlists
I tried this as per the wiki:
jorge@flamingo:~$ cat ~/.profile
# MPD daemon start (if no other user instance exists)
[ ! -s ~/.mpd/mpd.pid ] && mpd
but it didn't work. mpd was not running after reboot.
Then I tried /etc/profile:
jorge@flamingo:~$ cat /etc/profile
# /etc/profile
#Set our umask
umask 022
# Set our default path
PATH="/usr/local/sbin:/usr/local/bin:/usr/bin"
export PATH
# Load profiles from /etc/profile.d
if test -d /etc/profile.d/; then
for profile in /etc/profile.d/*.sh; do
test -r "$profile" && . "$profile"
done
unset profile
fi
# Source global bash config
if test "$PS1" && test "$BASH" && test -r /etc/bash.bashrc; then
. /etc/bash.bashrc
fi
# Termcap is outdated, old, and crusty, kill it.
unset TERMCAP
# Man is much better than us at figuring this out
unset MANPATH
export GPODDER_HOME="/home/jorge/Applications/Application Data/gpodder"
# MPD daemon start (if no other user instance exists)
[ ! -s ~/.mpd/mpd.pid ] && mpd
but it didn't work either.
In both cases, if I try to run mpd again from the terminal, I get:
jorge@flamingo:~$ mpd
server_socket: bind to '0.0.0.0:6600' failed: Address already in use (continuing anyway, because binding to '[::]:6600' succeeded)
and then mpd works.
Any ideas on how to startup mpd automatically on boot without systemd?
Last edited by geo909 (2014-09-26 04:03:15)

Similar Messages

  • I connected my iphone 3g to itunes which was in 4.1 firmware and itunes ask for an update which i downloaded an updated the phone to version 6.1.3 but my phone cannot start it shows no service my sim card is not getting network and i cannot use the phone.

    i connected my iphone 3g to itunes which was in 4.1 firmware and itunes ask for an update which i downloaded an updated the phone to version 6.1.3 but my phone cannot start it shows no service my sim card is not getting network and i cannot use the phone. what should i do.?

    First, you do not have a 3G if you could upgrade it to 6.1.3, because 4.2.1 is the last version that will work on the 3G. So you either have a 3GS or you somehow hacked the phone to install an incompatible version. You can check the model you have by entering your serial number here: https://selfsolve.apple.com/agreementWarrantyDynamic.do
    Assuming you have a 3GS the most likely reason for your problem is you have a gray market phone that was hacked or jailbroken to unlock it. When you upgraded it you removed the hack, so the phone is now locked to its original carrier.

  • Cannot start Oracle BI Scheduler service ---pls help.

    Hi all,
    I'm new in OBIEE.
    I already installed and created some reports and dashboards in OBIEE. I found the problems that they are not updated data when new data loaded into DB.
    I tried to start the Oracle BI Scheduler service but it has had the error like the message below;
    "The description for Event ID ( 21 ) in Source ( Oracle BI Scheduler ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer. You may be able to use the /AUXSOURCE= flag to retrieve this description; see Help and Support for details.
    The following information is part of the event: [68008] Scheduler Error: [nQSError: 67042] The Scheduler Configuration is incorrect.
    [nQSError: 67004] Registry value for SchedulerScriptPath not set.."
    Could anyone suggest me how would I be able to solve this error ?
    Thank you in advance.
    NNN

    hi
    First I do thank you for your answer quickly.
    For now, I have tried to follow your suggestion but I found a new error when I start bi scheduler service.
    ==========================================================================================
    The description for Event ID ( 21 ) in Source ( Oracle BI Scheduler ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer. You may be able to use the /AUXSOURCE= flag to retrieve this description; see Help and Support for details. The following information is part of the event: [68008] Scheduler Error:
    Current Table: S_NQ_JOB.
    [nQSError: 17001] Oracle Error code: 942, message: ORA-00942: table or view does not exist
    at OCI call OCIStmtExecute.
    [nQSError: 17010] SQL statement preparation failed.
    Current Table: S_NQ_JOB_PARAM.
    [nQSError: 17001] Oracle Error code: 942, message: ORA-00942: table or view does not exist
    at OCI call OCIStmtExecute.
    [nQSError: 17010] SQL statement preparation failed.
    Current Table: S_NQ_INSTANCE.
    [nQSError: 17001] Oracle Error code: 942, message: ORA-00942: table or view does not exist
    at OCI call OCIStmtExecute.
    [nQSError: 17010] SQL statement preparation failed.
    Current Table: S_NQ_ERR_MSG.
    [nQSError: 17001] Oracle Error code: 942, message: ORA-00942: table or view does not exist
    at OCI call OCIStmtExecute.
    [nQSError: 17010] SQL statement preparation failed..
    ===================================================================
    Any concern that I should know and how can I hanle this error ?
    Thank you

  • Cannot start the "Internet Directory" service for the infrastructure tier

    Hi, my "Internet Directory" service for the infrastructure tier cannot be started. I'm using 9iAS for Form service. Could anybody help me??
    Thanks much in advance!
    FreeBirdRita

    Hi Brain,
    what's version of SQL Server that you have installed and what's your operationg system version info?
    If you are running SQL Server 2008, which is not supported on the Windows Server 2008/2008 R2 domain controll (DC), even on Windows Server 2003 DC, there are limitations. Microsoft does not recommend to install SQL Server instances and DC on the same server,
    for more information, see Install SQL Server on a Domain Controller (http://msdn.microsoft.com/en-us/library/ms143506.aspx#DC_Support).
    There are some threads in the forum talked about installing SQL Server and DC on the same server, here are some for your references:
    http://social.technet.microsoft.com/Forums/en-US/sqlsetupandupgrade/thread/1a2963ff-90d7-4bba-97ce-fa15f70fb6a8/
    http://social.technet.microsoft.com/Forums/en-US/sqlsetupandupgrade/thread/981ef726-d04a-4063-8008-cc7bbad854ab/
    Hope this helps. Please feel free to let me know if you have more questions.
    Best Regards,
    Chunsong Feng [MSFT]
    Please remember to click "Mark as Answer" on the post that helps you, and to click "Unmark as Answer" if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

  • Cannot start Oracle BI Server Service

    I had installed Oracle Bussiness Intelligence 10g Release 2 version on my system....I was able to generate reports properly with the Default Repository(SH)....But When I created an OLAP repository and loaded it....It worked fine for a few minutes....then BI server service was automatically stopped....later when the service was restarted,it worked for 5 min but agin it got automatically stopped....but on attempting to restart the service again I got a error message ERROR 1068: Service cannot be be started because groups or dependencies not loaded....How can I reinstate the server process? I tried changing the repository to the default one but it didn't work....
    Edited by: user10422576 on Oct 19, 2008 11:42 PM

    I have seen similar errors when the repository is corrupt. Are you able to open the repository in offline mode ? In online mode, when you check consistencies, does it pass or does it throw any errors ? Also check the log files. if you are not getting enough information, try changing the loglevel for that user and then try it. usually this gives a good amount of info to debug.
    Good Luck.
    Dinesh Veera

  • Cannot start OEM console & agent service

    I have 8i database, client & OEM installled on the same laptob (OS W2k). Machine is not connected to any network.
    I have created the OEM repository.
    I can start OMS service.
    But the agent service fail to start.
    Microsof Mgt console error msg: could not start Oracle Agent service on Local Computer. Error3221356559
    Is it true the machine need a static IP address ?
    Any advice, deeply appreciated.
    Tks

    I had an agent service problem which after a lot of trouble resorted to a reinstall of OEM. It created the last 2 service errors being teh OEM and apache. I used a registry cleaner from
    www.iomation.com. After running this utility I rebooted and the agent service worked again. The apache service was fixed by starting it in the console and reading the error to find that multiple entries were being made to the http.conf when reinstalling. The OEM service still doesn't work. I am assuming it is a problem with a configuration file which I am working on now.
    Hope some of this helps, I know what a pain these problems are. Darrel, I dont know if its me, but that link doesnt work. Its a water/landscaping site.

  • Cannot start the Semantic Logging service for out-of-proc

    I used the following command in the “Package Manager Console” window to download the below mentioned packages
    • install-package EnterpriseLibrary.SemanticLogging
    • install-package EnterpriseLibrary.SemanticLogging.Service
    • install-package EnterpriseLibrary.SemanticLogging.TextFile
    Once the packages were installed, from the "packages\EnterpriseLibrary.SemanticLogging.Service.2.0.1406.1\tools” folder i extracted the install-packages.ps1 file using the following command
    "powershell –file .\install-packages.ps1"
    All the assemblies are now extracted into the directory.
    Now i try to start the service using the "SemanticLogging-svc.exe –s –a=LocalSystem" but the service did not start.
    Please help me out in this issue as i had followed the same procedure on a couple of other machines (one on a 32 bit machine which had Windows 7 Enterprise with SP1 and another a 64 bit machine which has Windows 8.1 Enterprise) and the service started and i
    could log using semantic logging block out-of-proc. I have got the powershell version 4 installed on my machine.
    I did not receive any error message which details me what issue was nor i got any success message which displayed the service has started. I am sure i got these last time when i tried out on the above said two machines. Right now i have a 64 bit machine
    with Windows 7 Enterprise with SP1.
    Appreciate your help

    This forum is for POS for .NET. You might want to try and post to the regular Windows forums:
    http://social.msdn.microsoft.com/Forums/en-US/winforms/threads
    www.annabooks.com / www.seanliming.com / Book Author - Pro Guide to WE8S, Pro Guide to WES 7, Pro Guide to POS for .NET

  • Cannot start the SQL server service after you install Active Directory

    Good Morning,
    Im the system admin for a small company.  We have a dedicated domain controller but it is the only one.  To get a second domain controller up and running on our domain, I installed the AD role on our file and SQL server.  After the reboot
    we couldnt get SQL up and running.  I found this article
    http://support.microsoft.com/kb/929665
    In the article it reads
    To work around this issue, repair Windows Internal Database. To do this, run the following command line at a command prompt:
    Msiexec /i SSEE_10.msi CALLERID=OCSetup.exe REINSTALL=ALL REINSTALLMODE=omus /qn REBOOT=ReallySupress /l*v <var><Log_File_Path></var>
    My question is what is the Log_File_Path?  Is that where I installed the AD log path?
    My DBA is also looking into this as well.
    Thanks in advance,
    Brian
    Brian Fink, MCSE

    Hi Brain,
    what's version of SQL Server that you have installed and what's your operationg system version info?
    If you are running SQL Server 2008, which is not supported on the Windows Server 2008/2008 R2 domain controll (DC), even on Windows Server 2003 DC, there are limitations. Microsoft does not recommend to install SQL Server instances and DC on the same server,
    for more information, see Install SQL Server on a Domain Controller (http://msdn.microsoft.com/en-us/library/ms143506.aspx#DC_Support).
    There are some threads in the forum talked about installing SQL Server and DC on the same server, here are some for your references:
    http://social.technet.microsoft.com/Forums/en-US/sqlsetupandupgrade/thread/1a2963ff-90d7-4bba-97ce-fa15f70fb6a8/
    http://social.technet.microsoft.com/Forums/en-US/sqlsetupandupgrade/thread/981ef726-d04a-4063-8008-cc7bbad854ab/
    Hope this helps. Please feel free to let me know if you have more questions.
    Best Regards,
    Chunsong Feng [MSFT]
    Please remember to click "Mark as Answer" on the post that helps you, and to click "Unmark as Answer" if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

  • I keep getting a message, "cannot start the Bluetooth Stack Service:, what does this mean

    I have the c510a photosmart estation, windows  7, 64 bit.  How can I get rid of this message? 

    I thought the same too, looks like its not just me having this issue, hope Apple do something soon. Thanks for your help

  • Unable to start MPD as a daemon in rc.conf

    For some reason, MPD is unable to start as a daemon listed in rc.conf. I have tried running it as a background also and no go. MPD goes after ALSA, so I don't know what else is missing.
    Also, I cannot start mpd as root after logging in immediately after my system boots up. It just tells me it fails.
    However, I can start MPD after I log-in as a normal user and su into root, then manually typing /etc/rc.d/mpd start.
    Could it be that it is unable to find my music database during its attempt to start as a daemon in rc.conf? (because my music directory is in an NTFS partition, which is not listed in fstab because it is automatically mounted by hal)
    Could it be that I set "user" in /etc/mpd.conf as "mpd" that it is unable to start it as root?
    What could be the culprit?
    Last edited by orv (2007-12-24 19:22:49)

    Yup. MPD works and plays my music. It just wont start up as a daemon, but I know why now.
    The place where my music is located (/dev/sdb2) is an NTFS partition which isn't mounted by the time I get to the login prompt. This is because it is automounted AFTER i log-in a user account in which HAL automounts that drive.
    Adding an entry in FSTAB and not relying on automount by HAL solves the problem because now when I start it as a daemon, it can actually find my music library.

  • Cannot start the OracleXETNSListener

    Hi,
    I installed the Oracle XE Beta 3 on XP SP2 (let's call this PC PC1).
    I cannot start it.
    the listener service doesn't start.
    ==> C:\oraclexe\app\oracle\product\10.2.0\server\BIN>net start
    OracleXETNSListener
    The OracleXETNSListener service is starting.
    The OracleXETNSListener service could not be started.
    The service did not report an error.
    As found in the forum, I tried
    to add "TRACE_LEVEL_LISTENER = USER " in listener.or
    to set SQLNET.AUTHENTICATION_SERVICES = (NONE) in sqlnet.ora
    I checked the ports used by my PC (netstat /ab) ==> 1521 is not used.
    I successfully installed it on another PC (PC2).
    - on PC2, using JDBC (ojdbc14.jar) from a java client, I can access to the oracle base on PC2
    but from my PC1, the same code doesn't work
    ==> java.sql.SQLException: Exception d'E/S: The Network Adapter could not establish the connection
    - but from PC1, I can access to another oracle DB (9.2.0 on hpux)
    Thanks a lot for your help.
    Guillaume

    LSNRCTL> status
    Message 1053 not found; No message file for product=NETWORK, facility=TNSTNS-12557: Message 12557 not found; No message file for product=NETWORK, facility=TNS
    TNS-12560: Message 12560 not found; No message file for product=NETWORK, facility=TNS
    TNS-00527: Message 527 not found; No message file for product=NETWORK, facility=TNS
    Guillaume

  • An error occurred while trying to start the Windows Deployment Services server

    After rebooting the server, I cannot start the Windows Deployment Services anymore.
    It worked perfectly before the reboot. When starting it manually these errors appear in the event log:
    The Windows Deployment Services Server service terminated with service-specific error 1460 (0x5B4).
    An error occurred while trying to initialize multicast manager. Windows Deployment Services server will be shutdown.
    Error Information: 0x5B4
    An error occurred while trying to start the Windows Deployment Services server.
    Error Information: 0x5B4
    This is on server standard beta 3.

    I have removed the server from the WDS, then I have uninstalled the role, rebooted, reinstalled the role.
    When I started the WDS the server was back in there, but when I wanted to start the service I got the message "the windows deployment services configuration is corrupt". I have triggered these commands to reset this:
    Code Snippet
    wdsutil /Verbose /Progress /Uninitialize-Server
    Windows Deployment Services Management Utility [Version 6.0.6001.16510]
    Copyright (C) Microsoft Corporation. All rights reserved.
    Tearing down server...
    == Original server operational mode: Native ==
    -> Resetting setup state
    -> Disabling and resetting Windows Deployment Services services
    -> Removing server BINL SCP
    -> Removing Windows Deployment Services share at \\LH-AJGG6OZWH9Z4.longhorn.offi
    ce\REMINST
    == Final server operational mode: Not Configured ==
    The command completed successfully.
    Then i did this command, but again it failed to start at the end.
    Code Snippet
    C:\Windows\system32>wdsutil /Verbose /Progress /Initialize-Server /REMINST:"c:\R
    emoteInstall"
    Windows Deployment Services Management Utility [Version 6.0.6001.16510]
    Copyright (C) Microsoft Corporation. All rights reserved.
    Setting up server...
    -> Creating Windows Deployment Services installation tree
    ---> Creating Windows Deployment Services installation root at \\LH-AJGG6OZWH9Z4
    .longhorn.office\c$\RemoteInstall
    ---> Creating Windows Deployment Services share at \\LH-AJGG6OZWH9Z4.longhorn.of
    fice\REMINST
    ---> Creating Windows Deployment Services folder \\LH-AJGG6OZWH9Z4.longhorn.offi
    ce\REMINST\Images
    ---> Creating Windows Deployment Services folder \\LH-AJGG6OZWH9Z4.longhorn.offi
    ce\REMINST\Boot
    ---> Creating Windows Deployment Services folder \\LH-AJGG6OZWH9Z4.longhorn.offi
    ce\REMINST\Boot\x86\Images
    ---> Creating Windows Deployment Services folder \\LH-AJGG6OZWH9Z4.longhorn.offi
    ce\REMINST\Boot\ia64\Images
    ---> Creating Windows Deployment Services folder \\LH-AJGG6OZWH9Z4.longhorn.offi
    ce\REMINST\Boot\x64\Images
    ---> Creating Windows Deployment Services folder \\LH-AJGG6OZWH9Z4.longhorn.offi
    ce\REMINST\Boot\Fonts
    ---> Creating Windows Deployment Services folder \\LH-AJGG6OZWH9Z4.longhorn.offi
    ce\REMINST\Tmp
    ---> Creating Windows Deployment Services folder \\LH-AJGG6OZWH9Z4.longhorn.offi
    ce\REMINST\Mgmt
    ---> Creating Windows Deployment Services folder \\LH-AJGG6OZWH9Z4.longhorn.offi
    ce\REMINST\WdsClientUnattend
    ---> Creating Windows Deployment Services folder \\LH-AJGG6OZWH9Z4.longhorn.offi
    ce\REMINST\Templates
    -> Installing Windows Deployment Services files
    ---> Installing system files
    ---> Installing boot files for x86
    ---> Installing boot files for ia64
    ---> Installing boot files for x64
    -> Updating registry
    -> Configuring the TFTPD service
    -> Configuring BINL SCP
    Enabling Windows Deployment Services services...
    Starting Windows Deployment Services services...
    An error occurred while trying to execute the command.
    Error Code: 0x41D
    Error Description: The service did not respond to the start or control request in a timely fashion.
    Anyone have an idea what could be the cause? I found this additional error in the event log, but distributed file system hasn't been installed since the beginning.
    DFS could not access its private data from the Active Directory. Please manually check network connectivity, security access, and/or consistency of DFS information in the Active Directory. This error occurred on root REMINST.

  • MS Exchange Information Store cannot start

    Hi all,
    Exchange Server 2010 information store cannot start, other exchange server services are running.
    it gives;
    The Microsoft Exchange Information Store service failed to start due to the following error: The system cannot find the file specified.
    There is no antivirus on the server.
    thanks for your helps.
    Mumin CICEK

    What happened right before the failure to mount, i.e. was it working prior and if so  did you have a power outage, software or firmware update etc
    What have you done so far
    Check your application event logs on the server and see it they offer any additional insight.  HINT; Filter the application log to only show warnings and errors, then retry the action and see what messages are created
    Search, Recover, & Extract Mailboxes, Folders, & Email Items from Offline Exchange Mailbox and Public Folder EDB's and Live Exchange Servers or Import/Migrate direct from Offline EDB to Any Production Exchange Server, even cross version i.e. 2003 -->
    2007 --> 2010 --> 2013 with Lucid8's
    DigiScope

  • Run custom systemd service before NetworkManager

    Hi, I am trying to write a systemd service that runs and completes before NetworkManager.service starts.
    I tried this:
    [Unit]
    Description=Custom service test
    Before=NetworkManager.service
    [Service]
    Type=oneshot
    ExecStart=/usr/bin/echo Custom service test 1
    ExecStart=/usr/bin/sleep 5
    ExecStart=/usr/bin/echo Custom service test 2
    [Install]
    WantedBy=network.target
    While the custom service does start, I got this rather strange output:
    Jan 22 00:12:46 localhost echo[1166]: Custom service test 1
    Jan 22 00:12:48 localhost kernel: NVRM: GPU at 0000:02:00: GPU-(snip)
    ... some unrelated messages (acpid, kdm, etc) ...
    Jan 22 00:12:49 localhost systemd-logind[1170]: Linked /tmp/.X11-unix/X0 to /run/user/1000/X11-display.
    Jan 22 00:13:13 localhost echo[1254]: Custom service test 2
    Jan 22 00:12:50 localhost systemd[1]: Started Custom service test.
    Jan 22 00:12:50 localhost systemd[1]: Starting Network Manager...
    As you can see, while everything appears in the expected order in the log, the timestamps look very wrong. The "Custom service test 2" says "00:13:13", yet it is in the middle of "00:12:49" and "00:12:50". What gives?
    Also, notice that the first echo was at 00:12:46, but NetworkManager started at 00:12:50, which is only 4 seconds later. The "sleep" in the custom services should have made it start at 00:12:51 at the earliest. I don't understand why things are not being respected.
    The output I'd expect to see is something like this:
    Jan 22 00:12:46 localhost echo[1166]: Custom service test 1
    Jan 22 00:12:51 localhost echo[1254]: Custom service test 2
    Jan 22 00:12:51 localhost systemd[1]: Started Custom service test.
    Jan 22 00:12:51 localhost systemd[1]: Starting Network Manager...
    I have also made sure that it shows up in NetworkManager.service's After list:
    $ systemctl show -p After NetworkManager.service
    After=mycustomservice.service syslog.target systemd-journald.socket dbus.socket basic.target

    falconindy wrote:Sooooo this begs the question: what are you really trying to do?
    I'm trying to write a script that changes the interface's MAC address before NetworkManager gets a chance to take over the network interface. I'm aware that there's a page about exactly that on the wiki. I started with the systemd service from the bottom of the page, which says "Before=dhcpcd@%i.service". I changed that line to use "NetworkManager.service", and I changed the ExecStart line to "/usr/bin/macchanger -A myinterface" in order to get a random MAC address, instead of setting a fixed one like the example shows. Then I saw that macchanger's output was being mixed with NetworkManager's output in the journal, so I decided to try and write a custom service just for testing, making it start before NetworkManager, in order to see if it really was systemd's fault or if it was something macchanger-specific. Then I noticed the strange behavior described in the OP, didn't really know what to do about it, so I posted this topic. That's the story so far...
    Last edited by WindPower (2013-01-23 00:13:22)

  • ERROR: Cannot start mail services, configuration directory does not exist

    I'm running an Xserve G5 with one internal boot drive and one RAID using the other two internal drives. I used Apple's Disk Utility to set-up the RAID.
    Back in early December, I moved my mail database and mail store to the RAID. Ever since, when I restart the server, the mailaccess.log generates the following error:
    Jan 23 18:51:33 mail master[47]: ERROR: Cannot start mail services, configuration directory does not exist: /Volumes/RAID/mail.data/db
    I'm speculating this is a timing error that gets created when Postfix initially can't find the RAID. Then, it must try again and find it because the error message does not repeat and mail starts running.
    Is this something to worry about?

    Hi Joel,
    You're right, it's a timing issues. The mail system is ready for work before the file system is mounted. It's benign.
    Jeff

Maybe you are looking for

  • Working with buttons and movies

    hi guys, amd fairly new to flash web design and have been trying to create my portfolio.However, i hv created thumbnails which i want 2 act as buttons and when click to ,i would like the main image to appear in the centre with others on the sides.som

  • Links in gmail and other emails won't work, have to use IE or Crome whats the solution

    My links in gmail as well as yahoo, only get a blank page - in the address bar it starts with https://mail.google.com/ = it ........it only brings me back to my inbox......... links works in IE as well as Chrome...

  • Will somebody at least just try to help me?

    I know it's getting annoying, but obviously I need help. Please. My computer won't log in. I enter the password, it says "logging in" and the blue and white bar is frozen. I'm then unable to click back or log in, and my mouse turns into the little pi

  • Remove HP ProtectTools fingerprints from bios?

    I dropped my laptop and the HDD broke from the shock. I just finished replacing the Hard drive, installed windows and all the drivers, installed HP ProtectTools and I tried to register my fingerprints in it again, but i cant. It says my fingerprints

  • MD 2013 unknowncomputer.asmx

    I am trying to set up web service using MDT 2013 for unknowncomputer.asmx file .  There are two functions that are not working  - GetADSite and GetAssingnedSite.  (Other three SCCM functions are working fine.) However if I install Maik Koster web ser