I've been trying to run an Icecast server for a while, without success.
I've installed it with Homebrew and MacPorts, but can't make it run either way.
When I enter icecast -c ~/.icecast.xml, Terminal doesn't return anything, and it stays like that indefinitely, unless I [1]+ Stopped it.
My config file icecast.xml was downloaded from this tutorial, though I'm using OS X Mavericks (10.9).
I haven't changed a single line of code from it. I'm stuck.
Any ideas?
<icecast>
<!-- location and admin are two arbitrary strings that are e.g. visible
on the server info page of the icecast web interface
(server_version.xsl). -->
<location>Earth</location>
<admin>admin#localhost</admin>
<limits>
<clients>100</clients>
<sources>2</sources>
<threadpool>5</threadpool>
<queue-size>524288</queue-size>
<client-timeout>30</client-timeout>
<header-timeout>15</header-timeout>
<source-timeout>10</source-timeout>
<!-- If enabled, this will provide a burst of data when a client
first connects, thereby significantly reducing the startup
time for listeners that do substantial buffering. However,
it also significantly increases latency between the source
client and listening client. For low-latency setups, you
might want to disable this. -->
<burst-on-connect>1</burst-on-connect>
<!-- same as burst-on-connect, but this allows for bre eing more
specific on how much to burst. Most people won't need to
change from the default 64k. Applies to all mountpoints -->
<burst-size>65535</burst-size>
</limits>
<authentication>
<!-- Sources log in with username 'source' -->
<source-password>hackme</source-password>
<!-- Relays log in username 'relay' -->
<relay-password>hackme</relay-password>
<!-- Admin logs in with the username given below -->
<admin-user>admin</admin-user>
<admin-password>hackme</admin-password>
</authentication>
<!-- set the mountpoint for a shoutcast source to use, the default if not
specified is /stream but you can change it here if an alternative is
wanted or an extension is required
<shoutcast-mount>/live.nsv</shoutcast-mount>
-->
<!-- Uncomment this if you want directory listings -->
<!--
<directory>
<yp-url-timeout>15</yp-url-timeout>
<yp-url>http://dir.xiph.org/cgi-bin/yp-cgi</yp-url>
</directory>
-->
<!-- This is the hostname other people will use to connect to your server.
It affects mainly the urls generated by Icecast for playlists and yp
listings. -->
<hostname>stream.myhouse.com</hostname>
<!-- You may have multiple <listener> elements -->
<listen-socket>
<port>8000</port>
<!-- <bind-address>127.0.0.1</bind-address> -->
<!-- <shoutcast-mount>/stream</shoutcast-mount> -->
</listen-socket>
<!--
<listen-socket>
<port>8001</port>
</listen-socket>
-->
<!--<master-server>127.0.0.1</master-server>-->
<!--<master-server-port>8001</master-server-port>-->
<!--<master-update-interval>120</master-update-interval>-->
<!--<master-password>hackme</master-password>-->
<!-- setting this makes all relays on-demand unless overridden, this is
useful for master relays which do not have <relay> definitions here.
The default is 0 -->
<!--<relays-on-demand>1</relays-on-demand>-->
<!--
<relay>
<server>127.0.0.1</server>
<port>8001</port>
<mount>/example.ogg</mount>
<local-mount>/different.ogg</local-mount>
<on-demand>0</on-demand>
<relay-shoutcast-metadata>0</relay-shoutcast-metadata>
</relay>
-->
<!-- Only define a <mount> section if you want to use advanced options,
like alternative usernames or passwords
<mount>
<mount-name>/example-complex.ogg</mount-name>
<username>othersource</username>
<password>hackmemore</password>
<max-listeners>1</max-listeners>
<dump-file>/tmp/dump-example1.ogg</dump-file>
<burst-size>65536</burst-size>
<fallback-mount>/example2.ogg</fallback-mount>
<fallback-override>1</fallback-override>
<fallback-when-full>1</fallback-when-full>
<intro>/example_intro.ogg</intro>
<hidden>1</hidden>
<no-yp>1</no-yp>
<authentication type="htpasswd">
<option name="filename" value="myauth"/>
<option name="allow_duplicate_users" value="0"/>
</authentication>
<on-connect>/home/icecast/bin/stream-start</on-connect>
<on-disconnect>/home/icecast/bin/stream-stop</on-disconnect>
</mount>
<mount>
<mount-name>/auth_example.ogg</mount-name>
<authentication type="url">
<option name="mount_add"
value="http://myauthserver.net/notify_mount.php"/>
<option name="mount_remove"
value="http://myauthserver.net/notify_mount.php"/>
<option name="listener_add"
value="http://myauthserver.net/notify_listener.php"/>
<option name="listener_remove"
value="http://myauthserver.net/notify_listener.php"/>
</authentication>
</mount>
-->
<fileserve>1</fileserve>
<paths>
<!-- basedir is only used if chroot is enabled -->
<basedir>/usr/local/Cellar/icecast/2.3.3/share/icecast</basedir>
<!-- Note that if <chroot> is turned on below, these paths must both
be relative to the new root, not the original root -->
<logdir>/usr/local/Cellar/icecast/2.3.3/var/log/icecast</logdir>
<webroot>/usr/local/Cellar/icecast/2.3.3/share/icecast/web</webroot>
<adminroot>/usr/local/Cellar/icecast/2.3.3/share/icecast/admin</adminroot>
<!-- <pidfile>/usr/local/Cellar/icecast/2.3.3/share/icecast/icecast.pid</pidfile> - ->
<!-- Aliases: treat requests for 'source' path as being for 'dest' path
May be made specific to a port or bound address using the "port"
and "bind-address" attributes.
-->
<!--
<alias source="/foo" destination="/bar"/>
-->
<!-- Aliases: can also be used for simple redirections as well,
this example will redirect all requests for http://server:port/ to
the status page
-->
<alias source="/" destination="/status.xsl"/>
</paths>
<logging>
<accesslog>access.log</accesslog>
<errorlog>error.log</errorlog>
<!-- <playlistlog>playlist.log</playlistlog> -->
<loglevel>3</loglevel> <!-- 4 Debug, 3 Info, 2 Warn, 1 Error -->
<logsize>10000</logsize> <!-- Max size of a logfile -->
<!-- If logarchive is enabled (1), then when logsize is reached
the logfile will be moved to [error|access|playlist].log.DATESTAMP,
otherwise it will be moved to [error|access|playlist].log.old.
Default is non-archive mode (i.e. overwrite)
-->
<!-- <logarchive>1</logarchive> -->
</logging>
<security>
<!-- <chroot>0</chroot> -->
<!--
<changeowner>
<user>nobody</user>
<group>nogroup</group>
</changeowner>
-->
</security>
</icecast>
If you install Icecast using Homebrew, the default configuration file will be placed at /usr/local/etc/icecast.xml, just edit it as you need.
I did not read your config, but it might be that there is an error in it somewhere, so just use the example config that is shipped with Icecast.
Related
I am creating a sysmon configuration to implement in my lab environment. This environment is used to build replica networks for troubleshooting problems and testing different software. I have created this sysmon configuration file to monitor the lab.
<Sysmon schemaversion="4.50">
<HashAlgorithms>md5,sha256</HashAlgorithms>
<EventFiltering>
<RuleGroup name="" groupRelation="or">
<!-- Process Creation -->
<ProcessCreate onmatch="include">
<CommandLine condition="contains"> </CommandLine>
</ProcessCreate>
<!-- Process Termination -->
<ProcessTerminate onmatch="include" />
<!-- File Creation -->
<FileCreateStreamHash onmatch="include">
<Image condition="is">*</Image>
</FileCreateStreamHash>
<!-- File Deletion -->
<FileDelete onmatch="include">
<TargetFilename condition="is">*</TargetFilename>
</FileDelete>
<!-- Network Connection -->
<NetworkConnect onmatch="include" />
<!-- Registry Changes -->
<RegistryEvent onmatch="include">
<TargetObject condition="contains">HKLM\System\CurrentControlSet\Services\Tcpip\Parameters\Interfaces</TargetObject>
<Details condition="contains">SetValueKey</Details>
</RegistryEvent>
<!-- Process Tampering Events -->
<ProcessTampering onmatch="include" />
<!-- Driver Loaded -->
<DriverLoad onmatch="include" />
<!-- Create Remote Thread -->
<CreateRemoteThread onmatch="include" />
<!-- Raw Access Read -->
<RawAccessRead onmatch="include" />
<!-- Pipe Created Event -->
<PipeEvent onmatch="include" />
<!-- WMI Event -->
<WmiEvent onmatch="include" />
<!-- DNS Events -->
<DnsQuery onmatch="include" />
<!-- File Creation Time -->
<FileCreateTime onmatch="include" />
<!-- Process Changed -->
<ProcessTampering onmatch="include" />
<!-- Monitoring Logs -->
<FileCreate onmatch="include">
<TargetFilename condition="contains">log</TargetFilename>
</FileCreate>
<!-- Monitoring Registry files -->
<RegistryEvent onmatch="include">
<TargetObject condition="contains">HKLM\System\CurrentControlSet\Services\Tcpip\Parameters\Interfaces</TargetObject>
<Details condition="contains">SetValueKey</Details>
</RegistryEvent>
<!-- Monitoring common malware hiding places -->
<FileCreate onmatch="include">
<TargetFilename condition="contains">AppData\Local\Temp</TargetFilename>
</FileCreate>
<FileCreate onmatch="include">
<TargetFilename condition="contains">ProgramData\Microsoft\Crypto\RSA\MachineKeys</TargetFilename>
</FileCreate>
</RuleGroup>
</EventFiltering>
</Sysmon>
Can any Microsoft wizards out there look it over for me and let me know if this looks sufficient and point me in a direction of how I should fine tune this config for my use case if not.
Thanks all!
I currently updated to visual studio 2017 enterprise edition version 15.9.24 .
The issue that i'm running across is i'm not able to debug my test using the
runsettings file. When I debug the test its access any dlls and deployed files from my TestResults Out folder instead of bin/debug folder since i'm in debug mode. When i was running Visual studio 2015 I was using .testsettings file
and was able to run my test from the bin/debug folder. Since .testsettings is
going to be deprecated i decided to move to runsettings.
Searching the web and stack someone stated that i needed to have the settings located in the runsettings file that is labeled DeploymentEnabled to false to achieve this. I did this and still getting error because the application is running and trying to access the files from my TestResults Out folder. I also changed the run settings to forced legacy mode to true and added directory of my old test settings file but still not working.
Is there another setting that i'm not taken into consideration
or am i missing something or is something wrong with my run settings.
Please see my example of my current runsettings file below
Thanks for any help or direction given.
<?xml version="1.0" encoding="utf-8"?>
<RunSettings>
<!-- Configurations that affect the Test Framework -->
<RunConfiguration>
<MaxCpuCount>1</MaxCpuCount>
<!-- Path relative to directory that contains .runsettings file
<ResultsDirectory>.\TestResults</ResultsDirectory> -->
<!-- x86 or x64 -->
<!-- You can also change it from the Test menu; choose "Processor Architecture for AnyCPU Projects" -->
<TargetPlatform>x86</TargetPlatform>
<!-- Framework35 | [Framework40] | Framework45 -->
<TargetFrameworkVersion>Framework45</TargetFrameworkVersion>
<!-- Path to Test Adapters -->
<!--<TestAdaptersPaths>%SystemDrive%\Temp\foo;%SystemDrive%\Temp\bar</TestAdaptersPaths>-->
<!-- TestSessionTimeout was introduced in Visual Studio 2017 version 15.5 -->
<!-- Specify timeout in milliseconds. A valid value should be greater than 0 -->
<TestSessionTimeout>15000000</TestSessionTimeout>
</RunConfiguration>
<!-- Configurations for data collectors -->
<DataCollectionRunSettings>
<DataCollectors>
<DataCollector friendlyName="Code Coverage" uri="datacollector://Microsoft/CodeCoverage/2.0" assemblyQualifiedName="Microsoft.VisualStudio.Coverage.DynamicCoverageDataCollector, Microsoft.VisualStudio.TraceCollector, Version=11.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<Configuration>
<CodeCoverage>
<ModulePaths>
<Exclude>
<ModulePath>.*CPPUnitTestFramework.*</ModulePath>
</Exclude>
</ModulePaths>
<!-- We recommend you do not change the following values: -->
<UseVerifiableInstrumentation>True</UseVerifiableInstrumentation>
<AllowLowIntegrityProcesses>True</AllowLowIntegrityProcesses>
<CollectFromChildProcesses>True</CollectFromChildProcesses>
<CollectAspDotNet>False</CollectAspDotNet>
</CodeCoverage>
</Configuration>
</DataCollector>
</DataCollectors>
</DataCollectionRunSettings>
<!-- Parameters used by tests at run time -->
<TestRunParameters>
<Parameter name="webAppUrl" value="http://localhost" />
<Parameter name="xxxxUser" value="xxxxm,xxxxtAuto01,xxxxtAuto02,xxxxxtAuto03,xxxxtAuto04" />
<Parameter name="xxxxxxxxxnbr" value="xx86,xx90,xx91,xx92,xx93" />
</TestRunParameters>
<!-- MSTest adapter -->
<MSTest>
<MapInconclusiveToFailed>true</MapInconclusiveToFailed>
<CaptureTraceOutput>false</CaptureTraceOutput>
<DeleteDeploymentDirectoryAfterTestRunIsComplete>true</DeleteDeploymentDirectoryAfterTestRunIsComplete>
<DeploymentEnabled>false</DeploymentEnabled>
<!---->
<ForcedLegacyMode>true</ForcedLegacyMode>
<SettingsFile>%xxxx_Automation_Test\xxxx_Automation_Test\xxx_Automation_Test\xxxxAutomation.testsettings;</SettingsFile>
<InProcMode>true</InProcMode>
<KeepExecutorAliveAfterLegacyRun>False</KeepExecutorAliveAfterLegacyRun>
<AssemblyResolution>
<!--
<Directory path="C:\xxx_Automation\xxxx_Automation_Test\xxx_Automation_Test\bin\" includeSubDirectories="false"/>-->
</AssemblyResolution>
</MSTest>
</RunSettings>
I updated my runsettings to have the file name of of run settings and to
update the ForcedLegacyMode to true.
<ForcedLegacyMode>true</ForcedLegacyMode>
<SettingsFile>xxxxxAutomation.testsettings</SettingsFile>
<KeepExecutorAliveAfterLegacyRun>False</KeepExecutorAliveAfterLegacyRun>
<AssemblyResolution>
I'm writing a simple Spring-based web application and deploy it to Websphere Liberty 8.5.5.9. The deployment fails because the application start fails. The message in console.log is
[ERROR ] CWWKZ0002E: An exception occurred while starting the application userSetting.
The exception message was: com.ibm.ws.container.service.metadata.MetaDataException:
com.ibm.wsspi.adaptable.module.UnableToAdaptException:
com.ibm.ws.javaee.ddmodel.DDParser$ParseException: CWWKC2262E: The server is
unable to process the 3.1 version and the http://xmlns.jcp.org/xml/ns/javaee namespace
in the /META-INF/web-fragment.xml deployment descriptor on line 23.
The last part of the message makes now sense since I don't hav /META-INF or /WEB-INF in the Eclipse project for the application, since I'm deploying with Gradle: gradle clean build deploy.
I've tried all kinds of modifications to the project and, in desperation, I've cut it down to only have the following source code:
#SpringBootApplication
public class UserSettingApplication {
private static final LoggerUtils logger = new LoggerUtils( UserSettingApplication.class );
public static void main(String[] args) {
logger.debug( "Entering UserSettingApplication.main()" );
SpringApplication.run(UserSettingApplication.class, args);
}
}
Can you please advise me how to fix this service start-up problem?
server.xml:
<?xml version="1.0" encoding="UTF-8"?>
<server description="new server">
<!-- Enable features -->
<featureManager>
<feature>jsp-2.2</feature>
</featureManager>
<featureManager>
<feature>adminCenter-1.0</feature>
</featureManager>
<!-- Define the host name for use by the collective.
If the host name needs to be changed, the server should be
removed from the collective and re-joined. -->
<variable name="defaultHostName" value="localhost" />
<!-- Define an Administrator and non-Administrator -->
<basicRegistry id="basic">
<user name="admin" password="********" />
<user name="nonadmin" password="***********" />
</basicRegistry>
<!-- Assign 'admin' to Administrator -->
<administrator-role>
<user>admin</user>
</administrator-role>
<keyStore id="defaultKeyStore" password="*******" />
<!-- To access this server from a remote client add a host attribute to the following element, e.g. host="*" -->
<httpEndpoint id="defaultHttpEndpoint"
host="*"
httpPort="9080"
httpsPort="9443" />
<!-- Automatically expand WAR files and EAR files -->
<applicationManager autoExpand="false"/>
</server>
This error appears to be caused by some of your build tooling generating a web-fragment.xml with a Servlet 3.1 schema.
Currently, you have the jsp-2.2 feature enabled, which by default enables servlet-3.0.
To fix the problem, I would recommend upgrading from jsp-2.2 to jsp-2.3 (which will pull in servlet-3.1), or adding <feature>webProfile-7.0</feature> to just enable all of the Java EE 7 web profile features (servlet, JPA, bean validation, cdi, jsf, etc).
So your new server.xml could look like this:
<server description="new server">
<!-- Enable features -->
<featureManager>
<feature>jsp-2.3</feature>
<feature>adminCenter-1.0</feature>
</featureManager>
<!-- rest of file unchanged.... -->
I am new to WebSphere Liberty profile. I am working on 17.0.0.4 version. What I am trying to achieve is to have custom JAAS login setup for the application. The application works fine on WebSphere 8.5.
I have reviewed so many link from IBM Knowledge Center for the same, but got result with either or with JAAS custom login, but not both of them together. With WebSphere 8.5 we are having level of hierarchy to decide which authentication mechanism goes where, but with Liberty if I setup Custom JAAS authentication mechanism then I can't login to WebSphere Liberty AdminCenter, and if I configure server.xml for , then it does not authenticate my application's user (because it is designed to get authenticate users via JAAS).
Here is my server.xml file.
<?xml version="1.0" encoding="UTF-8"?>
<server description="new server">
<!-- Enable features -->
<featureManager>
<feature>adminCenter-1.0</feature>
<feature>ssl-1.0</feature>
<feature>webProfile-7.0</feature>
<feature>appSecurity-2.0</feature>
</featureManager>
<keyStore id="defaultKeyStore" password="WASLiberty" />
<!-- Admin Center username/password -->
<!--<quickStartSecurity userName="admin" userPassword="admin123" />-->
<!-- Define an Administrator and non-Administrator -->
<basicRegistry id="basic">
<user name="admin" password="{xor}PjsyNjFubWw=" /> <!-- Encoded version of "admin123" -->
<user name="nonadmin" password="nonadmin123" />
</basicRegistry>
<!-- Assign 'admin' to Administrator -->
<administrator-role>
<user>admin</user>
</administrator-role>
<!-- JNDI Connection configuration -->
<dataSource id="MY_CUSTOM_DS" jndiName="jdbc/MY_CUSTOM_DS">
<jdbcDriver libraryRef="sqlserverjdbc"/>
<properties.microsoft.sqlserver databaseName="mydb"
serverName="localhost" portNumber="1433"
user="sa" password="root" />
</dataSource>
<!-- JDBC Driver file location -->
<library id="sqlserverjdbc">
<file name="${wlp.install.dir}/lib/sqljdbc4.jar"/>
</library>
<library id="MyLoginModuleLib">
<fileset dir="${wlp.install.dir}/lib" includes="custom_auth.jar"/>
</library>
<!-- JAAS Login Module for web application -->
<jaasLoginModule id="myCustom"
className="com.kana.auth.websphere.MyLoginModule"
controlFlag="REQUIRED" libraryRef="MyLoginModuleLib">
<options myOption1="value1" myOption2="value2"/>
</jaasLoginModule>
<!-- JAAS Login Context -->
<jaasLoginContextEntry id="system.WEB_INBOUND" name="system.WEB_INBOUND"
loginModuleRef="myCustom, hashtable, userNameAndPassword, certificate, token" />
<!-- To access this server from a remote client add a host attribute to the following element, e.g. host="*" -->
<httpEndpoint id="defaultHttpEndpoint"
host="*"
httpPort="9080"
httpsPort="9443" />
<webApplication contextRoot="mywebapp" location="mywebapp.war" />
<!-- Automatically expand WAR files and EAR files -->
<applicationManager autoExpand="true"/>
<!-- Enable remote file access -->
<remoteFileAccess>
<writeDir>${server.config.dir}</writeDir>
</remoteFileAccess>
</server>
Can anyone please point out where I am making mistake?
If you are using custom JAAS login module, then your custom JAAS login module need to ignore the admin center authentication and let the default login modules handle it.
The better option is to use custom TAI to handle application authentication and let the default login modules handle the admin center authentication.
Regards,
Ut Le
Many many thanks Ut Le for providing solution.
From the log file, found that the root cause was ClassNotFound exception. It does not have class which I was pointing to from <jaasLoginModule>. Later on found that I was pointing to jar file which is not at that location. So that was a silly mistake I made for configuration.
I want to know because page of deploy tool in my local installation of admin center is blocked (I've installed WAS Liberty in my PC)
I get this message:
Cannot access host or deploy rules information on the server
This is my server.xml
<server description="new server">
<!-- Enable features -->
<featureManager>
<feature>javaee-7.0</feature>
<feature>localConnector-1.0</feature>
<feature>adminCenter-1.0</feature>
<feature>collectiveController-1.0</feature>
<feature>collectiveMember-1.0</feature>
</featureManager>
<!-- This template enables security. To get the full use of all the capabilities, a keystore and user registry are required. -->
<!-- For the keystore, default keys are generated and stored in a keystore. To provide the keystore password, generate an
encoded password using bin/securityUtility encode and add it below in the password attribute of the keyStore element.
Then uncomment the keyStore element. -->
<!--
<keyStore password=""/>
-->
<!--For a user registry configuration, configure your user registry. For example, configure a basic user registry using the
basicRegistry element. Specify your own user name below in the name attribute of the user element. For the password,
generate an encoded password using bin/securityUtility encode and add it in the password attribute of the user element.
Then uncomment the user element. -->
<basicRegistry id="basic" realm="BasicRealm">
<!-- <user name="yourUserName" password="" /> -->
<user name="admin" password="adminpwd"/>
</basicRegistry>
<!-- To access this server from a remote client add a host attribute to the following element, e.g. host="*" -->
<httpEndpoint httpPort="9080" httpsPort="9444" id="defaultHttpEndpoint"/>
<!-- Automatically expand WAR files and EAR files -->
<applicationManager autoExpand="true"/>
<keyStore location="${server.output.dir}/resources/security/liberty.jks" password="adminadmin"/>
<administrator-role>
<user>admin</user>
</administrator-role>
<remoteFileAccess>
<writeDir>${server.config.dir}</writeDir>
</remoteFileAccess>
<applicationMonitor updateTrigger="mbean"/>
<webApplication id="prueba" location="prueba.war" name="prueba"/>
</server>
Thanks for your help.
Hard to be sure from the information provided, but my guess is that you manually added the collectiveController-1.0 feature, but didn't actually create the collective (which you would by running the 'collective create {serverName}' command from wlp/bin. Since the deploy tool is only applicable on a collective controller, if it's not configured properly it will not work.
You can find detailed instructions for creating a collective here: https://www.ibm.com/support/knowledgecenter/SSAW57_liberty/com.ibm.websphere.wlp.nd.multiplatform.doc/ae/tagt_wlp_configure_collective.html