Closed mbundes closed 3 years ago
Thanks for the post. In the log above, it looks like Shairport Sync is already running as a daemon -- it's using port 5000.
Shairport Sync is set to output to the default device. If you haven't changed the alsa
defaults, that may be the headphone jack or the HDMI output. (I never change the alsa
settings and In my experience, the default is always the headphone jack.) However, as set up, Shairport Sync does not control the hardware mixer (i.e. the hardware volume control), so it is possible that all you need to do is turn up the mixer level on the default output card. You can use alsamixer
for that. When you get it going, you can hook the mixer control up to Shairport Sync.
Thanks for your answer. 5000 port use for Home Assistant. Yes, I need jack connection. Can we change port here? Can you give me simple instructions? 😊 Thanks
You can change port in the configuration file, sure.
Only change port in config? 😳
Also on the command line.
Changed the port three times. The service was restarted. The error is the same.
$ shairport-sync -vvu
0.000144720 "shairport.c:461" looking for configuration file at full path "/etc/shairport-sync.conf"
0.001887653 "shairport.c:1729" Started!
0.000314625 "shairport.c:1756" software version: "3.3.8rc1-OpenSSL-Avahi-ALSA-soxr-sysconfdir:/etc"
0.000290754 "shairport.c:1762" log verbosity is 2.
0.000248848 "audio_alsa.c:998" alsa: init() -- alsa_backend_state => abm_disconnected.
0.000212126 "audio_alsa.c:1015" alsa: alsa_maximum_stall_time of 0.200000 sec.
0.000241422 "audio_alsa.c:1302" alsa: disable_standby_mode is "never".
0.000035777 "audio_alsa.c:1304" alsa: disable_standby_mode_silence_threshold is 0.040000 seconds.
0.000207496 "audio_alsa.c:1306" alsa: disable_standby_mode_silence_scan_interval is 0.004000 seconds.
0.000371883 "audio_alsa.c:1345" alsa: output device name is "hw:Headphones".
0.000391586 "shairport.c:1777" The processor is running little-endian.
0.000046369 "shairport.c:1810" disable resend requests is off.
0.000042870 "audio_alsa.c:1943" keep_dac_busy is now "no"
0.000036574 "shairport.c:1814" diagnostic_drop_packet_fraction is 0.000000. A value of 0.0 means no packets will be dropped deliberately.
0.000272365 "shairport.c:1815" statistics_requester status is 0.
0.000154998 "shairport.c:1820" rtsp listening port is 5025.
0.000149979 "shairport.c:1821" udp base port is 6001.
0.000150923 "shairport.c:1822" udp port range is 10.
0.000149349 "shairport.c:1823" player name is "Колонки на кухне".
0.000146109 "shairport.c:1824" backend is "alsa".
0.000148164 "shairport.c:1825" run_this_before_play_begins action is "(null)".
0.000144701 "shairport.c:1826" run_this_after_play_ends action is "(null)".
0.000149091 "shairport.c:1827" wait-cmd status is 0.
0.000149793 "shairport.c:1828" run_this_before_play_begins may return output is 0.
0.000144942 "shairport.c:1829" run_this_if_an_unfixable_error_is_detected action is "(null)".
0.000149442 "shairport.c:1830" run_this_before_entering_active_state action is "(null)".
0.000151090 "shairport.c:1831" run_this_after_exiting_active_state action is "(null)".
0.000472733 "shairport.c:1832" active_state_timeout is 10.000000 seconds.
0.000038481 "shairport.c:1833" mdns backend "(null)".
0.000149534 "shairport.c:1834" userSuppliedLatency is 0.
0.000162887 "shairport.c:1837" interpolation setting is "auto".
0.000147219 "shairport.c:1838" interpolation soxr_delay_threshold is 30.
0.000026518 "shairport.c:1839" resync time is 0.050000 seconds.
0.000153072 "shairport.c:1840" allow a session to be interrupted: 0.
0.000033721 "shairport.c:1841" busy timeout time is 120.
0.000026185 "shairport.c:1842" drift tolerance is 0.001995 seconds.
0.000026852 "shairport.c:1843" password is "(null)".
0.000025147 "shairport.c:1844" ignore_volume_control is 0.
0.000222441 "shairport.c:1848" volume_max_db is not set
0.000033018 "shairport.c:1850" volume range in dB (zero means use the range specified by the mixer): 60.
0.000147738 "shairport.c:1854" volume_range_combined_hardware_priority (1 means hardware mixer attenuation is used first) is 0.
0.000162016 "shairport.c:1856" playback_mode is 0 (0-stereo, 1-mono, 1-reverse_stereo, 2-both_left, 3-both_right).
0.000158886 "shairport.c:1857" disable_synchronization is 0.
0.000032685 "shairport.c:1858" use_mmap_if_available is 1.
0.000144627 "shairport.c:1860" output_format automatic selection is enabled.
0.000148220 "shairport.c:1864" output_rate automatic selection is enabled.
0.000147997 "shairport.c:1868" audio backend desired buffer length is 0.200000 seconds.
0.000154646 "shairport.c:1870" audio_backend_buffer_interpolation_threshold_in_seconds is 0.120000 seconds.
0.000181293 "shairport.c:1871" audio backend latency offset is 0.000000 seconds.
0.000157146 "shairport.c:1873" audio backend silence lead-in time is "auto".
0.000027018 "shairport.c:1877" zeroconf regtype is "_raop._tcp".
0.000026203 "shairport.c:1878" decoders_supported field is 1.
0.000025481 "shairport.c:1879" use_apple_decoder is 0.
0.000025333 "shairport.c:1880" alsa_use_hardware_mute is 0.
0.000024981 "shairport.c:1884" no special mdns service interface was requested.
0.000063628 "shairport.c:1888" configuration file name "/etc/shairport-sync.conf" resolves to "/etc/shairport-sync.conf".
0.000032759 "shairport.c:1917" loudness is 0.
0.000025833 "shairport.c:1918" loudness reference level is -20.000000
0.001419735 "rtsp.c:2896" unable to listen on IPv4 port 5025. The error is: "Address already in use".
0.000112332 "rtsp.c:2896" unable to listen on IPv6 port 5025. The error is: "Address already in use".
0.000221552 "rtsp.c:3028" *fatal error: could not establish a service on port 5025 -- program terminating. Is another instance of Shairport Sync running on this device?
0.000041110 "shairport.c:1424" emergency exit
Is Shairport Sync also running as a daemon? (See above.)
$ sudo service shairport-sync restart done
How else to check?
Thanks. I'm afraid you'll have to educate yourself about standard Linux techniques -- that's not really our role.
Thanks for your cooperation
This issue has been inactive for 60 days so will be closed 7 days from now. To prevent this, please remove the "stale" label or post a comment.
When shairport is started on Pi, sound redirected from my MacBook Pro or Iphone to the shairport server running on Pi, I cannot hear sound. Spotify on Home Assistant server work correctly.